[PATCH] l2_packet: fix eloop leak when using l2_packet_none

Maxime Bizon mbizon
Thu Mar 20 11:24:53 PDT 2014


Signed-off-by: Maxime Bizon <mbizon at freebox.fr>
---
 src/l2_packet/l2_packet_none.c |    2 --
 1 file changed, 2 deletions(-)

diff --git a/src/l2_packet/l2_packet_none.c b/src/l2_packet/l2_packet_none.c
index b01e830..2663768 100644
--- a/src/l2_packet/l2_packet_none.c
+++ b/src/l2_packet/l2_packet_none.c
@@ -84,7 +84,6 @@ struct l2_packet_data * l2_packet_init(
 	 * TODO: open connection for receiving frames
 	 */
 	l2->fd = -1;
-	eloop_register_read_sock(l2->fd, l2_packet_receive, l2, NULL);
 
 	return l2;
 }
@@ -96,7 +95,6 @@ void l2_packet_deinit(struct l2_packet_data *l2)
 		return;
 
 	if (l2->fd >= 0) {
-		eloop_unregister_read_sock(l2->fd);
 		/* TODO: close connection */
 	}
 		
-- 
1.7.9.5




More information about the Hostap mailing list