about summary refs log tree commit diff stats
path: root/core/conf/rc.d/wlan
diff options
context:
space:
mode:
Diffstat (limited to 'core/conf/rc.d/wlan')
-rwxr-xr-xcore/conf/rc.d/wlan19
1 files changed, 11 insertions, 8 deletions
diff --git a/core/conf/rc.d/wlan b/core/conf/rc.d/wlan
index 894a69c..86910bc 100755
--- a/core/conf/rc.d/wlan
+++ b/core/conf/rc.d/wlan
@@ -2,15 +2,17 @@
 #
 # /etc/rc.d/wlan: start/stop wireless interface
 #
+
 DEV=wlp7s0
 
+
 SSD=/sbin/start-stop-daemon
 PROG_DHCP=/sbin/dhcpcd
 PROG_WIFI=/usr/sbin/wpa_supplicant
-PID_DHCP=/var/run/dhcpcd-${DEV}.pid
+PID_DHCP=/var/run/dhcpcd.pid
 PID_WIFI=/var/run/wpa_supplicant.pid
 
-OPTS_DHCP="-h $(/bin/hostname) -C resolv.conf $DEV"
+OPTS_DHCP="--waitip -h $(/bin/hostname) -z $DEV"
 OPTS_WIFI="-B -P $PID_WIFI -D nl80211,wext -c /etc/wpa_supplicant.conf -i $DEV"
 
 print_status() {
@@ -30,13 +32,15 @@ case $1 in
 		RETVAL=$?
 		;;
 	stop)
-		( $SSD --stop --retry 10 --pidfile $PID_DHCP
+		( $SSD --stop --retry 10 --pidfile $PID_DHCP 
 		  $SSD --stop --retry 10 --pidfile $PID_WIFI )
+
 		RETVAL=$?
-                /sbin/ip route del default dev ${DEV}
-		/sbin/ip route flush dev ${DEV}
-		/sbin/ip link set ${DEV} down
-		/sbin/ip addr flush dev ${DEV}
+		  /sbin/ip route del default dev ${DEV}
+                  /sbin/ip route flush dev ${DEV}
+                  /sbin/ip link set ${DEV} down
+                  /sbin/ip addr flush dev ${DEV}
+
 		;;
 	restart)
 		$0 stop
@@ -54,4 +58,3 @@ esac
 exit $RETVAL
 
 # End of file
-