Code

Make 'cvs ci' lockless in git-cvsserver by using git-update-ref
authorJunio C Hamano <junkio@cox.net>
Wed, 21 Feb 2007 05:54:39 +0000 (21:54 -0800)
committerJunio C Hamano <junkio@cox.net>
Tue, 27 Feb 2007 23:44:40 +0000 (15:44 -0800)
commitada5ef3b48be7ded62af1f9b7fdb71db3024ac71
treef9ebafa7ae1dd97f011e374b2c4d41862cef562f
parent4e4b55dd0f5b4644767265f7c16a8b370278ce56
Make 'cvs ci' lockless in git-cvsserver by using git-update-ref

This makes "ci" codepath lockless by following the usual
"remember the tip, do your thing, then compare and swap at the
end" update pattern using update-ref.  Incidentally, by updating
the code that reads where the tip of the head is to use
show-ref, it makes it safe to use in a repository whose refs are
pack-pruned.

I noticed that other parts of the program are not yet pack-refs
safe, but tried to keep the changes to the minimum.

Signed-off-by: Junio C Hamano <junkio@cox.net>
git-cvsserver.perl