[OpenWrt-Devel] [PATCH] netifd: fix an error message during network shutdown

Michel Stam m.stam at fugro.nl
Thu Oct 2 09:27:24 EDT 2014


When 'wifi down' is called by /etc/init.d/network, it is run from
stop_service( ). This function is in turn invoked from stop( ).
stop( ) messes up the order by first procd_kill-ing the network
settings, then calling wifi to down the wifi networking
interfaces. By redefining stop( ) instead, the proper order is
restored.

Signed-off-by: Michel Stam <m.stam at fugro.nl>
---
 package/network/config/netifd/files/etc/init.d/network | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/package/network/config/netifd/files/etc/init.d/network b/package/network/config/netifd/files/etc/init.d/network
index 1d8a5b3..fbba9ec 100755
--- a/package/network/config/netifd/files/etc/init.d/network
+++ b/package/network/config/netifd/files/etc/init.d/network
@@ -32,8 +32,9 @@ reload_service() {
 	/sbin/wifi reload_legacy
 }
 
-stop_service() {
+stop() {
 	/sbin/wifi down
+	procd_kill network ''
 }
 
 service_running() {
-- 
1.7.12.1
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list