projects
/
platform
/
kernel
/
linux-3.10.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2fdf213
)
uml: drivers/slip_user.c memory leak fix
author
Vitaliy Ivanov
<vitalivanov@gmail.com>
Tue, 26 Jul 2011 00:12:51 +0000
(17:12 -0700)
committer
Linus Torvalds
<torvalds@linux-foundation.org>
Tue, 26 Jul 2011 03:57:13 +0000
(20:57 -0700)
Do not free memory when you failed to allocate it.
Signed-off-by: Vitaliy Ivanov <vitalivanov@gmail.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/um/drivers/slip_user.c
patch
|
blob
|
history
diff --git
a/arch/um/drivers/slip_user.c
b/arch/um/drivers/slip_user.c
index
a1c2d2c
..
cbacfc4
100644
(file)
--- a/
arch/um/drivers/slip_user.c
+++ b/
arch/um/drivers/slip_user.c
@@
-102,7
+102,7
@@
static int slip_tramp(char **argv, int fd)
"buffer\n");
os_kill_process(pid, 1);
err = -ENOMEM;
- goto out_
fre
e;
+ goto out_
clos
e;
}
close(fds[1]);
@@
-112,7
+112,6
@@
static int slip_tramp(char **argv, int fd)
err = helper_wait(pid);
close(fds[0]);
-out_free:
kfree(output);
return err;