diff --git a/hooks/pre-auto-gc b/hooks/pre-auto-gc index c4107f51..ec29be43 100755 --- a/hooks/pre-auto-gc +++ b/hooks/pre-auto-gc @@ -29,7 +29,7 @@ then exit 0 fi -if test -x /sbin/on_ac_power && /sbin/on_ac_power +if test -x /sbin/on_ac_power && (/sbin/on_ac_power;test $? -ne 1) then exit 0 elif test "$(cat /sys/class/power_supply/AC/online 2>/dev/null)" = 1