When a script using locking.sh is stopped by ctrl-C, the lock file remains.
We have to wait 100 seconds for releasing the lock at the next time.
Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
then
owner="$new_owner"
retries=0
+ else
+ local pid=$(echo $owner | cut -d : -f 1)
+ if [ ! -f "/proc/$pid/status" ]
+ then
+ _release_lock $lockdir
+ fi
fi
if [ $retries -gt $LOCK_SPINNING_RETRIES ]