Commit f1834686 authored by Leigh Stoller's avatar Leigh Stoller

Minor bug fix.

parent 548cb7e2
...@@ -318,7 +318,7 @@ sub TBScriptLock($;$$$) ...@@ -318,7 +318,7 @@ sub TBScriptLock($;$$$)
my $ltype = ($shared ? LOCK_SH : LOCK_EX); my $ltype = ($shared ? LOCK_SH : LOCK_EX);
while (flock(LOCK, $ltype|LOCK_NB) == 0) { while (flock(LOCK, $ltype|LOCK_NB) == 0) {
return TBSCRIPTLOCK_WOULDBLOCK() return TBSCRIPTLOCK_WOULDBLOCK()
if ($flags & TBSCRIPTLOCK_NONBLOCKING()); if (defined($flags) && ($flags & TBSCRIPTLOCK_NONBLOCKING()));
print "Another $token is in progress (${tries}s). Waiting ...\n" print "Another $token is in progress (${tries}s). Waiting ...\n"
if (($tries++ % 60) == 0); if (($tries++ % 60) == 0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment