Fixed bug in the restart of wpa_supplicant

suites/experimental
KatolaZ 8 years ago
parent 74ab155e2c
commit 32fd87f1db
  1. 5
      ChangeLog
  2. 5
      setnet.sh

@ -1,3 +1,8 @@
2017-03-08 KatolaZ <katolaz@freaknet.org>
* setnet.sh (wifi_restart_wpa): Corrected a bug in the restart of
wpa_supplicant.
2017-03-07 KatolaZ <katolaz@freaknet.org>
* setnet.sh (check_deps): Corrected a small bug in the parsing of options

@ -1142,9 +1142,12 @@ wifi_restart_wpa(){
WPA_PID=$(ps ax | grep wpa_supplicant | grep " -i ${DEVNAME} " |
sed -r -e 's/^\ +//g' | cut -d " " -f 1)
if [ -n "${WPA_PID}" ]; then
log "wifi_restart_wpa" "WPA_PID: ${WPA_PID}"
kill -9 ${WPA_PID}
else
log "wifi_restart_wpa" "no wpa_supplicant is running!!!"
fi
wpa_supplicant -B -i ${DEVNAME} -c ${WPA_FILE} -P${WPA_PIDFILE} 2>&1 >/dev/null
WPA_PID=$(ps ax | grep wpa_supplicant | grep " -i ${DEVNAME}" | \
sed -r -e 's/^\ +//g' | cut -d " " -f 1 )

Loading…
Cancel
Save