Linux wireless drivers development
 help / color / mirror / Atom feed
* [PATCH] hostapd: fix eloop warning
@ 2007-08-15 11:08 Johannes Berg
  2007-08-16  1:46 ` Jouni Malinen
  0 siblings, 1 reply; 3+ messages in thread
From: Johannes Berg @ 2007-08-15 11:08 UTC (permalink / raw)
  To: Jouni Malinen; +Cc: linux-wireless

This fixes a warning that occurs when turning off hostapd.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>

---
Thought I'd send that earlier but it seems I forgot.
This is a slightly modified version of my original patch, please do test
it as I've not been able to test it right now. The original was fine
though, but it shut down the eloop in wireless_event_deinit instead of
here.

--- hostap.orig/hostapd/driver_devicescape.c	2007-08-15 13:06:48.000000000 +0200
+++ hostap/hostapd/driver_devicescape.c	2007-08-15 13:07:39.000000000 +0200
@@ -1954,8 +1954,10 @@ static void i802_deinit(void *priv)
 
 	(void) hostapd_set_iface_flags(drv, 0);
 
-	if (drv->sock >= 0)
+	if (drv->sock >= 0) {
+		eloop_unregister_read_sock(drv->sock);
 		close(drv->sock);
+	}
 	if (drv->ioctl_sock >= 0)
 		close(drv->ioctl_sock);
 



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-08-16 13:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-15 11:08 [PATCH] hostapd: fix eloop warning Johannes Berg
2007-08-16  1:46 ` Jouni Malinen
2007-08-16 13:24   ` Johannes Berg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox