Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
58054382e2 | |||
04ff160a7d |
4
rc.in
4
rc.in
@@ -129,10 +129,10 @@ rc.boot() {
|
||||
}
|
||||
|
||||
rc.halt() {
|
||||
if type -P halt; then
|
||||
if type -P halt &>/dev/null; then
|
||||
function rc.halt_poweroff { halt -p; }
|
||||
function rc.halt_reboot { halt -r; }
|
||||
elif [[ -f /proc/sysrq-trigger ]]; then
|
||||
elif (( $(</proc/sys/kernel/sysrq) )); then
|
||||
function rc.halt_poweroff { echo 'o' > /proc/sysrq-trigger; }
|
||||
function rc.halt_reboot { echo 'b' > /proc/sysrq-trigger; }
|
||||
else
|
||||
|
Reference in New Issue
Block a user