1
0
mirror of https://github.com/gryf/wicd.git synced 2025-12-25 16:02:28 +01:00

Apply patch from rworkman

Update suspend/resume script
This commit is contained in:
Dan O'Reilly
2008-12-11 00:56:12 -05:00
parent 254d7c55dc
commit 2b47ff538e
2 changed files with 14 additions and 21 deletions

View File

@@ -17,10 +17,6 @@ wicd_start() {
else
echo "Starting wicd daemon..."
wicd 2>/dev/null 1>&2
# Activate the pm-utils sleep hook
if [ ! -x %PMUTILS%55wicd ]; then
chmod +x %PMUTILS%55wicd
fi
fi
}
@@ -32,11 +28,6 @@ wicd_stop() {
else
pkill -f python.*wicd-daemon.py 2>/dev/null
fi
# Deactivate the pm-utils sleep hook
if [ -x %PMUTILS%55wicd ]; then
chmod -x %PMUTILS%55wicd
fi
}
# See how we were called and take appropriate action

View File

@@ -6,24 +6,26 @@
wicd_suspend()
{
# Put wifi interface down
%LIB%suspend.py
# Put wifi interface down
%LIB%suspend.py 2>/dev/null
return $NA
}
wicd_resume()
{
# Bring wifi interface back up
%LIB%autoconnect.py
# Bring wifi interface back up
%LIB%autoconnect.py 2>/dev/null
return $NA
}
case "$1" in
hibernate|suspend)
wicd_suspend
;;
thaw|resume)
wicd_resume
;;
*) exit $NA
;;
hibernate|suspend)
wicd_suspend
;;
thaw|resume)
wicd_resume
;;
*) exit $NA
;;
esac