if [ "x$gateway" != "x" ]
then
ping -c 1 $gateway
- mactest=$(arp -n -a $gateway | awk '{print $4}')
+ mactest=$(arp -n -a $gateway | awk '{print $4}' | head -1)
fi
date >> /tmp/nm.set
done
else
echo "On a foreign network, make sure we clean up" >> /tmp/nm.set
- for user in $(ls /home/*/bin/network-bookmarks-remove | sed 's/\/home\///; s/\/.*//')
+ for user in $(ls /home/*/.gtk-bookmarks | sed 's/\/home\///; s/\/.*//')
do
- sudo -u $user /home/$user/bin/network-bookmarks-remove
+ sudo -u $user /usr/bin/network-bookmarks-remove
done
/etc/init.d/autofs stop