]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
depcomp: use "rmdir", not "rm -rf", to remove the empty lock directory
authorStefano Lattarini <stefano.lattarini@gmail.com>
Thu, 18 Oct 2012 11:24:21 +0000 (13:24 +0200)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Sat, 24 Nov 2012 14:52:41 +0000 (15:52 +0100)
* lib/depcomp (pgcc): Here.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
lib/depcomp

index 2ccf719359c93d6d5aa0b3f3d472dfa5ae3f7f68..973c389a891485a9e3b9e0ef5ffa130d08c97d7c 100755 (executable)
@@ -363,7 +363,7 @@ pgcc)
   # problems in parallel builds.  Use a locking strategy to avoid stomping on
   # the same $tmpdepfile.
   lockdir=$base.d-lock
-  trap "echo '$0: caught signal, cleaning up...' >&2; rm -rf $lockdir" 1 2 13 15
+  trap "echo '$0: caught signal, cleaning up...' >&2; rmdir $lockdir" 1 2 13 15
   numtries=100
   i=$numtries
   while test $i -gt 0 ; do
@@ -373,7 +373,7 @@ pgcc)
       "$@" -MD
       stat=$?
       # Release the lock.
-      rm -rf $lockdir
+      rmdir $lockdir
       break
     else
       ## the lock is being held by a different process,