Browse Source

netifd: add udhcpc link check to dhcp shell handler script

Fixes the assumption the busybox udhcpc applet is always enabled; in case
the symbolic link check fails the DHCP shell handler script will exit and
as result the DHCP protocol handler will not be registered in netifd.

Signed-off-by: Hans Dedecker <[email protected]>
Hans Dedecker 7 years ago
parent
commit
175b262328

+ 1 - 1
package/network/config/netifd/Makefile

@@ -1,7 +1,7 @@
 include $(TOPDIR)/rules.mk
 include $(TOPDIR)/rules.mk
 
 
 PKG_NAME:=netifd
 PKG_NAME:=netifd
-PKG_RELEASE:=4
+PKG_RELEASE:=5
 
 
 PKG_SOURCE_PROTO:=git
 PKG_SOURCE_PROTO:=git
 PKG_SOURCE_URL=$(PROJECT_GIT)/project/netifd.git
 PKG_SOURCE_URL=$(PROJECT_GIT)/project/netifd.git

+ 2 - 0
package/network/config/netifd/files/lib/netifd/proto/dhcp.sh

@@ -1,5 +1,7 @@
 #!/bin/sh
 #!/bin/sh
 
 
+[ -L /sbin/udhcpc ] || exit 0
+
 . /lib/functions.sh
 . /lib/functions.sh
 . ../netifd-proto.sh
 . ../netifd-proto.sh
 init_proto "$@"
 init_proto "$@"