]> git.plutz.net Git - cgilite/commitdiff
suppress error message from mkdir
authorPaul Hänsch <paul@plutz.net>
Sun, 15 Jul 2018 15:28:50 +0000 (17:28 +0200)
committerPaul Hänsch <paul@plutz.net>
Sun, 15 Jul 2018 15:28:50 +0000 (17:28 +0200)
storage.sh

index 8939fdc7c83fcb9bdde8cc1738ed1e4baabc3963..f5a0ac6c58feb4de7ae8285b32f28e4b4c47780d 100755 (executable)
@@ -28,7 +28,7 @@ LOCK(){
     return 1
   fi
 
-  while ! mkdir "$lock"; do
+  while ! mkdir "$lock" 2>&-; do
     block="$(cat "$lock/pid" || printf 1)"
     if ! { ps -eo pid |grep -qwF "$block"; }; then
       printf 'Overriding stale lock: %s\n' "$lock" >&2