--- scriptlets.d.old/network 2007-07-09 08:23:35.000000000 -0700 +++ scriptlets.d.old/network 2008-01-20 13:26:34.000000000 -0800 @@ -29,10 +29,13 @@ # Don't bring down lo in auto mode. [ "$int" = "lo" ] && continue fi - vecho 2 "Bringing down interface $int" - network_ifdown $int - [ $? -ne 0 ] && ret=1 - NETWORK_DOWNEDIFS="$int $NETWORK_DOWNEDIFS" + # Only bring down interfaces that are actually up. + if network_if_is_up $int ; then + vecho 2 "Bringing down interface $int" + network_ifdown $int + [ $? -ne 0 ] && ret=1 + NETWORK_DOWNEDIFS="$int $NETWORK_DOWNEDIFS" + fi done return $ret } @@ -97,6 +100,9 @@ network_ifdown() { [ -x "/etc/init.d/net.$1" ] && /etc/init.d/net.$1 stop } + network_if_is_up() { + [ -x "/etc/init.d/net.$1" ] && return `/etc/init.d/net.$1 --quiet status` + } ;; suse) network_ifup() { --- scriptlets.d.old/xstatus 2006-06-04 23:16:26.000000000 -0700 +++ scriptlets.d.old/xstatus 2008-01-20 13:33:32.000000000 -0800 @@ -15,6 +15,9 @@ ### KDE bits: XStatusProgressStart_kde() { + # Check if KDE is running. + [ -z `pidof -s kdesktop` ] && return 1 + KDEPB_DCOPREF= # Set $PATH for distros that aren't quite standard. @@ -33,7 +36,7 @@ return 0 fi - KDEPB_DCOPREF="`su $XUSER -c \"$KSTART_BIN --windowclass KDialog --alldesktops $KDIALOG_BIN --title Hibernating --progressbar \\\"$1\\\" 100\"`" + KDEPB_DCOPREF="`su $XUSER -c \"$KSTART_BIN --windowclass KDialog --alldesktops $KDIALOG_BIN --title Hibernating --icon kmenu --progressbar \\\"$1\\\" 100\"`" su $XUSER -c "$DCOP_BIN \"$KDEPB_DCOPREF\" showCancelButton 1" }