diff --git a/pm/sleep.d/55NetworkManager b/pm/sleep.d/55NetworkManager index f3c6df5..8675eeb 100755 --- a/pm/sleep.d/55NetworkManager +++ b/pm/sleep.d/55NetworkManager @@ -11,11 +11,12 @@ suspend_nm() { # Tell NetworkManager to shut down networking - printf "Having NetworkManager put all interaces to sleep..." - dbus_send --system \ + printf "Having NetworkManager put all interaces to sleep..." + dbus_send --system --print-reply \ --dest=org.freedesktop.NetworkManager \ /org/freedesktop/NetworkManager \ - org.freedesktop.NetworkManager.sleep && \ + org.freedesktop.NetworkManager.Sleep \ + boolean:true && \ echo Done. || echo Failed. } @@ -23,10 +24,11 @@ resume_nm() { # Wake up NetworkManager and make it do a new connection printf "Having NetworkManager wake interfaces back up..." - dbus_send --system \ - --dest=org.freedesktop.NetworkManager \ - /org/freedesktop/NetworkManager \ - org.freedesktop.NetworkManager.wake && \ + dbus_send --system --print-reply \ + --dest=org.freedesktop.NetworkManager \ + /org/freedesktop/NetworkManager \ + org.freedesktop.NetworkManager.Sleep \ + boolean:false && \ echo Done. || echo Failed. }