wok-6.x rev 15645
wpa_supplicant: fail safe post_install
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Tue Dec 10 13:16:06 2013 +0000 (2013-12-10) |
parents | 2e44cbfb4fc3 |
children | e585bcc8453e |
files | wpa_supplicant/receipt |
line diff
1.1 --- a/wpa_supplicant/receipt Tue Dec 10 13:11:40 2013 +0000 1.2 +++ b/wpa_supplicant/receipt Tue Dec 10 13:16:06 2013 +0000 1.3 @@ -66,12 +66,12 @@ 1.4 # Pre and post install commands for Tazpkg. 1.5 post_install() 1.6 { 1.7 - grep -q ^WPA_OPTIONS= $1/etc/daemons.conf || cat >> $1/etc/daemons.conf <<EOT 1.8 + grep -qs ^WPA_OPTIONS= $1/etc/daemons.conf || cat >> $1/etc/daemons.conf <<EOT 1.9 # wpa_supplicant daemon options 1.10 WPA_OPTIONS="-B -u -P /var/run/wpa_supplicant.pid -c /etc/wpa_supplicant.conf -i \$(. /etc/network.conf ; echo \$WIFI_INTERFACE)" 1.11 1.12 EOT 1.13 # 'w' option dont exist anymore with < 0.6.9 1.14 - sed -i s/'-Bw'/'-B'/ $1/etc/daemons.conf 1.15 - sed -i s/'-B -w'/'-B'/g $1/etc/init.d/network.sh 1.16 + sed -i s/'-Bw'/'-B'/ $1/etc/daemons.conf 2> /dev/null 1.17 + sed -i s/'-B -w'/'-B'/g $1/etc/init.d/network.sh 2> /dev/null 1.18 }