K 10
svn:author
V 6
iulius
K 8
svn:date
V 27
2008-11-18T15:11:03.782324Z
K 7
svn:log
V 702
Fix a long-standing bug in shlock.  Thanks a lot to Berend Reitsma
for his fix.

The race condition is that there is a timewindow between the discovery
of an invalid lock and the removal of that lockfile.  The lockfile that
is removed might be another file than the one you checked.  This can
happen because another shlock might have done the same check but did
not yet remove the lockfile because of OS scheduling.  You will happily
remove the file, create a new lockfile and return success.  If the OS
then schedules the other shlock again, it will continue to remove the
lockfile, create a new lockfile and return success too.  At this point
you have two processes running within the locked part...

END
