1
0
mirror of https://github.com/git/git.git synced 2024-10-03 07:01:22 +02:00
Git Source Code Mirror. Please follow Documentation/SubmittingPatches procedure for any of your improvements.
Go to file
Grégoire Barbier 9116de5957 http-push: fix webdav lock leak.
Releasing webdav lock even if push fails because of bad (or no)
reference on command line.

To reproduce the issue that this patch fixes, prepare a test repository
availlable over http+webdav, say at http://myhost/myrepo.git/

Then:

  $ git clone http://myhost/myrepo.git/
  $ cd myrepo
  $ git push http
  Fetching remote heads...
    refs/
    refs/heads/
    refs/tags/
  No refs in common and none specified; doing nothing.
  $ git push http
  Fetching remote heads...
    refs/
    refs/heads/
    refs/tags/
  No refs in common and none specified; doing nothing.
  $

Finally, you look at the web server logs, and will find one LOCK query
and no UNLOCK query, of course the second one will be in 423 return
code instead of 200:

1.2.3.4 - gb [19/Jan/2008:14:24:56 +0100] "LOCK /myrepo.git/info/refs HTTP/1.1" 200 465
(...)
1.2.3.4 - gb [19/Jan/2008:14:25:10 +0100] "LOCK /myrepo.git/info/refs HTTP/1.1" 423 363

With this patch, there would have be two UNLOCKs in addition of the LOCKs

From the user's point of view:

- If you realize that you should have typed e.g. "git push http
  master" instead of "git push http", you will have to wait for 10
  minutes for the lock to expire by its own.

- Furthermore, if somebody else is dumb enough to type "git push http"
  while you need to push "master" branch, then you'll need too to wait
  for 10 minutes too.

Signed-off-by: Gr.ANigoire Barbier <gb@gbarbier.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-01-20 15:17:58 -08:00
arm
compat
contrib Update git-completion for new 'remote rm' option 2008-01-19 23:06:02 -08:00
Documentation doc typo: s/prior committing/prior to committing/ 2008-01-19 11:25:37 -08:00
git-gui
gitk-git Merge ../gitk 2008-01-11 00:51:30 -08:00
gitweb
mozilla-sha1
perl
ppc
t send-email: add no-validate option 2008-01-18 13:33:57 -08:00
templates Officially deprecate repo-config. 2008-01-17 22:52:40 -08:00
xdiff
.gitignore
.mailmap
alloc.c
archive-tar.c
archive-zip.c
archive.c Move sha1_file_to_archive into libgit 2008-01-18 12:33:50 -08:00
archive.h
attr.c
attr.h
base85.c
blob.c
blob.h
builtin-add.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-annotate.c
builtin-apply.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-archive.c Move sha1_file_to_archive into libgit 2008-01-18 12:33:50 -08:00
builtin-blame.c
builtin-branch.c
builtin-bundle.c
builtin-cat-file.c
builtin-check-attr.c
builtin-check-ref-format.c
builtin-checkout-index.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-clean.c git-clean: fix off-by-one memory access when given no arguments 2008-01-12 11:10:09 -08:00
builtin-commit-tree.c
builtin-commit.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-config.c
builtin-count-objects.c
builtin-describe.c
builtin-diff-files.c
builtin-diff-index.c
builtin-diff-tree.c
builtin-diff.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-fast-export.c
builtin-fetch--tool.c
builtin-fetch-pack.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-fetch.c
builtin-fmt-merge-msg.c
builtin-for-each-ref.c
builtin-fsck.c Make 'git fsck' complain about non-commit branches 2008-01-16 11:37:57 -08:00
builtin-gc.c slightly better auto gc message 2008-01-07 14:02:25 -08:00
builtin-grep.c
builtin-http-fetch.c
builtin-init-db.c
builtin-log.c
builtin-ls-files.c
builtin-ls-remote.c ls-remote: add -t and -h options. 2008-01-15 17:04:21 -08:00
builtin-ls-tree.c
builtin-mailinfo.c
builtin-mailsplit.c
builtin-merge-base.c
builtin-merge-file.c
builtin-merge-ours.c
builtin-mv.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-name-rev.c
builtin-pack-objects.c pack-objects: remove redundant and wrong call to deflateEnd() 2008-01-10 23:27:39 -08:00
builtin-pack-refs.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-prune-packed.c
builtin-prune.c
builtin-push.c
builtin-read-tree.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-reflog.c
builtin-rerere.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-reset.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-rev-list.c
builtin-rev-parse.c
builtin-revert.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-rm.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-send-pack.c
builtin-shortlog.c shortlog: mention the "-e" option in the usage 2008-01-09 12:25:27 -08:00
builtin-show-branch.c
builtin-show-ref.c
builtin-stripspace.c
builtin-symbolic-ref.c
builtin-tag.c
builtin-tar-tree.c
builtin-unpack-objects.c
builtin-update-index.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin-update-ref.c
builtin-upload-archive.c
builtin-verify-pack.c
builtin-verify-tag.c
builtin-write-tree.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
builtin.h
bundle.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
bundle.h
cache-tree.c
cache-tree.h
cache.h Fix random fast-import errors when compiled with NO_MMAP 2008-01-17 22:39:20 -08:00
check-builtins.sh
check-racy.c
color.c
color.h
combine-diff.c
command-list.txt Officially deprecate repo-config. 2008-01-17 22:52:40 -08:00
commit.c parse_commit_buffer: tighten checks while parsing 2008-01-20 11:00:57 -08:00
commit.h
config.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
config.mak.in autoconf: Add checking for unsetenv function 2008-01-17 23:35:36 -08:00
configure.ac autoconf: Add checking for unsetenv function 2008-01-17 23:35:36 -08:00
connect.c
convert.c treat any file with NUL as binary 2008-01-16 09:10:34 -08:00
copy.c
COPYING
csum-file.c
csum-file.h
ctype.c
daemon.c
date.c
decorate.c
decorate.h
delta.h
diff-delta.c
diff-lib.c
diff.c color unchanged lines as "plain" in "diff --color-words" 2008-01-18 01:29:38 -08:00
diff.h
diffcore-break.c
diffcore-delta.c
diffcore-order.c
diffcore-pickaxe.c
diffcore-rename.c
diffcore.h
dir.c
dir.h
dump-cache-tree.c
entry.c
environment.c
exec_cmd.c
exec_cmd.h
fast-import.c fast-import: Don't use a maybe-clobbered errno value 2008-01-18 13:19:37 -08:00
fetch-pack.h
fixup-builtins
generate-cmdlist.sh
git-add--interactive.perl
git-am.sh
git-archimport.perl
git-bisect.sh
git-checkout.sh
git-clone.sh
git-compat-util.h
git-cvsexportcommit.perl
git-cvsimport.perl cvsimport: remove last use of repo-config from git standard tools 2008-01-13 21:48:22 -08:00
git-cvsserver.perl
git-filter-branch.sh
git-help--browse.sh
git-instaweb.sh
git-lost-found.sh
git-merge-octopus.sh
git-merge-one-file.sh
git-merge-resolve.sh
git-merge-stupid.sh
git-merge.sh
git-mergetool.sh Allow git-mergetool to handle paths with a leading space 2008-01-07 21:00:54 -08:00
git-parse-remote.sh
git-pull.sh
git-quiltimport.sh
git-rebase--interactive.sh Squelch bogus progress output from git-rebase--interactive 2008-01-14 20:04:02 -08:00
git-rebase.sh
git-relink.perl
git-remote.perl
git-repack.sh
git-request-pull.sh
git-send-email.perl send-email: add no-validate option 2008-01-18 13:33:57 -08:00
git-sh-setup.sh
git-stash.sh
git-submodule.sh
git-svn.perl git-svn: handle leading/trailing whitespace from svnsync revprops 2008-01-12 10:58:06 -08:00
GIT-VERSION-GEN GIT 1.5.4-rc3 2008-01-11 21:40:55 -08:00
git.c
git.spec.in RPM spec: include gitk message files. 2008-01-11 21:40:25 -08:00
grep.c
grep.h
hash-object.c
hash.c
hash.h
help.c
http-push.c http-push: fix webdav lock leak. 2008-01-20 15:17:58 -08:00
http-walker.c
http.c
http.h
ident.c
imap-send.c
index-pack.c
INSTALL
interpolate.c
interpolate.h
list-objects.c
list-objects.h
lockfile.c close_lock_file(): new function in the lockfile API 2008-01-16 15:35:03 -08:00
log-tree.c
log-tree.h
mailmap.c
mailmap.h
Makefile Move sha1_file_to_archive into libgit 2008-01-18 12:33:50 -08:00
match-trees.c
merge-file.c
merge-index.c
merge-recursive.c Improve use of lockfile API 2008-01-16 15:35:35 -08:00
merge-tree.c
mktag.c
mktree.c
object-refs.c
object.c
object.h
pack-check.c
pack-redundant.c
pack-write.c
pack.h
pager.c
parse-options.c
parse-options.h
patch-delta.c
patch-id.c
patch-ids.c
patch-ids.h
path-list.c
path-list.h
path.c
pkt-line.c
pkt-line.h
pretty.c
progress.c
progress.h
quote.c
quote.h
reachable.c
reachable.h
read-cache.c
README
receive-pack.c
reflog-walk.c
reflog-walk.h
refs.c refs.c: rework ref_locks by abstracting from underlying struct lock_file 2008-01-16 15:36:10 -08:00
refs.h
RelNotes GIT 1.5.3.8 2008-01-07 22:41:43 -08:00
remote.c
remote.h
revision.c
revision.h
run-command.c
run-command.h
send-pack.h
server-info.c
setup.c
sha1_file.c Fix random fast-import errors when compiled with NO_MMAP 2008-01-17 22:39:20 -08:00
sha1_name.c
shallow.c
shell.c
show-index.c
sideband.c recv_sideband: Do not use ANSI escape sequence on dumb terminals. 2008-01-09 12:23:59 -08:00
sideband.h
strbuf.c
strbuf.h
symlinks.c
tag.c
tag.h
tar.h
test-absolute-path.c
test-chmtime.c
test-date.c
test-delta.c
test-genrandom.c
test-match-trees.c
test-parse-options.c
test-sha1.c
test-sha1.sh
trace.c
transport.c
transport.h
tree-diff.c
tree-walk.c tree-walk: don't parse incorrect entries 2008-01-06 18:41:44 -08:00
tree-walk.h
tree.c
tree.h
unpack-file.c
unpack-trees.c
unpack-trees.h
update-server-info.c
upload-pack.c
usage.c
utf8.c utf8_width(): allow non NUL-terminated input 2008-01-06 20:53:46 -08:00
utf8.h utf8_width(): allow non NUL-terminated input 2008-01-06 20:53:46 -08:00
var.c
walker.c
walker.h
write_or_die.c
ws.c
wt-status.c
wt-status.h
xdiff-interface.c
xdiff-interface.h

////////////////////////////////////////////////////////////////

	GIT - the stupid content tracker

////////////////////////////////////////////////////////////////

"git" can mean anything, depending on your mood.

 - random three-letter combination that is pronounceable, and not
   actually used by any common UNIX command.  The fact that it is a
   mispronunciation of "get" may or may not be relevant.
 - stupid. contemptible and despicable. simple. Take your pick from the
   dictionary of slang.
 - "global information tracker": you're in a good mood, and it actually
   works for you. Angels sing, and a light suddenly fills the room.
 - "goddamn idiotic truckload of sh*t": when it breaks

Git is a fast, scalable, distributed revision control system with an
unusually rich command set that provides both high-level operations
and full access to internals.

Git is an Open Source project covered by the GNU General Public License.
It was originally written by Linus Torvalds with help of a group of
hackers around the net. It is currently maintained by Junio C Hamano.

Please read the file INSTALL for installation instructions.
See Documentation/tutorial.txt to get started, then see
Documentation/everyday.txt for a useful minimum set of commands,
and "man git-commandname" for documentation of each command.
CVS users may also want to read Documentation/cvs-migration.txt.

Many Git online resources are accessible from http://git.or.cz/
including full documentation and Git related tools.

The user discussion and development of Git take place on the Git
mailing list -- everyone is welcome to post bug reports, feature
requests, comments and patches to git@vger.kernel.org. To subscribe
to the list, send an email with just "subscribe git" in the body to
majordomo@vger.kernel.org. The mailing list archives are available at
http://marc.theaimsgroup.com/?l=git and other archival sites.

The messages titled "A note from the maintainer", "What's in
git.git (stable)" and "What's cooking in git.git (topics)" and
the discussion following them on the mailing list give a good
reference for project status, development direction and
remaining tasks.