summary refs log tree commit diff
diff options
context:
space:
mode:
authorJuan RP <xtraeme@gmail.com>2014-08-05 15:42:52 +0200
committerJuan RP <xtraeme@gmail.com>2014-08-05 15:42:52 +0200
commit378f5ff48f484592607a68908354559949385647 (patch)
tree5aed558e535d8c7b2f9306eda40e0ed66de532d9
parentb4255008b158e76fe595ec7d3021121b9d2257dd (diff)
downloadrunit-void-378f5ff48f484592607a68908354559949385647.tar.gz
runit-void-378f5ff48f484592607a68908354559949385647.tar.xz
runit-void-378f5ff48f484592607a68908354559949385647.zip
shutdown: fix write test.
-rwxr-xr-xshutdown.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/shutdown.sh b/shutdown.sh
index 0cf5c24..1fa8a5f 100755
--- a/shutdown.sh
+++ b/shutdown.sh
@@ -37,7 +37,7 @@ if [ "$action" = "cancel" ]; then
   exit
 fi
 
-if [ ! -w /run/runit/shutdown.pid ]; then
+if ! touch /run/runit/shutdown.pid 2>/dev/null; then
   echo "Not enough permissions to execute ${0#*/}"
   exit 1
 fi