View | Details | Raw Unified | Return to bug 749031
Collapse All | Expand All

(-) (-5 / +6 lines)
Line  Link Here
-- hooks/sleep.d/50rcnetwork
Lines 16-32 Link Here
16
[ -r /etc/sysconfig/network/config ] && . /etc/sysconfig/network/config
16
[ -r /etc/sysconfig/network/config ] && . /etc/sysconfig/network/config
17
[ -r /etc/sysconfig/network/scripts/functions ] && . /etc/sysconfig/network/scripts/functions
17
[ -r /etc/sysconfig/network/scripts/functions ] && . /etc/sysconfig/network/scripts/functions
18
18
19
command_exists dhcp_clients || exit $NA
20
21
# NetworkManager is handled by 55NetworkManager, so skip this script if
19
# NetworkManager is handled by 55NetworkManager, so skip this script if
22
# nm is enabled in sysconfig ...
20
# nm is enabled in sysconfig ...
23
[ x"${NETWORKMANAGER}" -eq x"yes" ] && exit $NA
21
[ x"${NETWORKMANAGER}" = x"yes" ] && exit $NA
24
# ... or if is running
22
# ... or if is running
25
command_exists nm_running && nm_running && exit $NA
23
command_exists nm_running && nm_running && exit $NA
26
24
25
# check network/scripts/function provides dhcp_interfaces()
26
# function returning a list of interfaces with running dhcp.
27
command_exists dhcp_interfaces || exit $NA
28
27
case "$1" in
29
case "$1" in
28
    hibernate|suspend)
30
    hibernate|suspend)
29
        save_state "dhcp_clients" "`dhcp_clients`"
31
        save_state "dhcp_clients" "`dhcp_interfaces`"
30
        service network stop-all-dhcp-clients
32
        service network stop-all-dhcp-clients
31
        ;;
33
        ;;
32
    thaw|resume)
34
    thaw|resume)

Return to bug 749031