git-annex/debian
Joey Hess 3334130368
Fix shared lock file FD leak.
This fixes behavior in this situation:

	l1 <- lockShared Nothing "lck"
	l2 <- lockShared Nothing "lck"
	dropLock l1
	dropLock l2

Before, the lock was dropped upon the second dropLock call, but the fd
remained open, and would never be closed while the program was running.

Fixed by a rather round-about method, but it should work well enough.

It would have been simpler to open open the shared lock once, and not open
it again in the second call to lockShared. But, that's difficult to do
atomically.

This also affects Windows and PID locks, not just posix locks.

In the case of pid locks, multiple calls to waitLock within the same
process are allowed because the side lock is locked using a posix lock,
and so multiple exclusive locks can be taken in the same process. So,
this change fixes a similar problem with pid locks.

	l1 <- waitLock (Seconds 1) "lck"
	l2 <- waitLock (Seconds 1) "lck"
	dropLock l1
	dropLock l2

Here the l2 side lock fd remained open but not locked,
although the pid lock file was removed. After this change, the second
dropLock will close both fds to the side lock, and delete the pidlock.
2016-03-01 15:31:39 -04:00
..
patches Make git-annex-standalone.deb include the git-annex html documentation, desktop file, and base completion file, same as the regular git-annex.deb. 2015-11-10 13:21:05 -04:00
tests Debian: Run the builtin test suite as an autopkgtest. 2013-08-15 15:49:19 +02:00
cabal-wrapper support building with BUILDER=stack to use stack instead of cabal 2015-12-28 14:18:47 -04:00
changelog Fix shared lock file FD leak. 2016-03-01 15:31:39 -04:00
compat debhelper v9 2012-01-15 14:53:38 -04:00
control Update perlmagick build dependency. Closes: #789225 2016-02-18 13:09:43 -04:00
copyright The pre-commit-annex hook script that automatically extracts metadata has been updated to also use exiftool. Thanks, Klaus Ethgen. 2016-02-28 11:10:55 -04:00
create-standalone-changelog use BuildVersion in debian, which fixes windows build 2015-04-21 16:42:54 -04:00
doc-base Add doc-base file. Closes: #621408 2011-04-06 21:57:22 -04:00
git-annex.lintian-overrides merge lintian overrides from debian 2015-08-15 11:45:37 -04:00
NEWS prep release 2013-10-02 16:13:45 -04:00
rules move -j1 setting to BUILDEROPTIONS, set in debian/rules file 2016-02-05 13:56:27 -04:00