projects
/
mech_eap.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1f1e599
)
rfkill: Fix a memory leak
author
Jouni Malinen
<jouni@qca.qualcomm.com>
Mon, 15 Feb 2016 22:14:47 +0000
(
00:14
+0200)
committer
Jouni Malinen
<j@w1.fi>
Mon, 15 Feb 2016 22:14:47 +0000
(
00:14
+0200)
rfkill_init() uses realpath() which allocates memory and that memory was
not freed on the success path.
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
src/drivers/rfkill.c
patch
|
blob
|
history
diff --git
a/src/drivers/rfkill.c
b/src/drivers/rfkill.c
index
464cf78
..
4d4d1b4
100644
(file)
--- a/
src/drivers/rfkill.c
+++ b/
src/drivers/rfkill.c
@@
-185,6
+185,7
@@
struct rfkill_data * rfkill_init(struct rfkill_config *cfg)
if (!found)
goto fail2;
+ free(phy);
eloop_register_read_sock(rfkill->fd, rfkill_receive, rfkill, NULL);
return rfkill;