aboutsummaryrefslogtreecommitdiff
path: root/http-push.c
diff options
context:
space:
mode:
authorEygene Ryabinkin <rea-git@codelabs.ru>2007-02-28 12:12:02 -0800
committerJunio C Hamano <junkio@cox.net>2007-02-28 12:12:02 -0800
commit2c46759db757eb742590e8547cb0c63e8bdb1da1 (patch)
tree8164f8a8b9f1c93a5008eb7288ae0c41609d6697 /http-push.c
parentcf70c16fc0661ec562b01222055b8be4bfd1a7e7 (diff)
downloadgit-2c46759db757eb742590e8547cb0c63e8bdb1da1.tar.gz
git-2c46759db757eb742590e8547cb0c63e8bdb1da1.tar.xz
http-push.c::lock_remote(): validate all remote refs.
Starting from offset 11 might have been good back when it was only used for updating "refs/heads/*", but it is used to update "info/refs" and "refs/tags/*" as well. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'http-push.c')
-rw-r--r--http-push.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/http-push.c b/http-push.c
index b128c0146..cec7bf7fa 100644
--- a/http-push.c
+++ b/http-push.c
@@ -1295,7 +1295,7 @@ static struct remote_lock *lock_remote(const char *path, long timeout)
sprintf(url, "%s%s", remote->url, path);
/* Make sure leading directories exist for the remote ref */
- ep = strchr(url + strlen(remote->url) + 11, '/');
+ ep = strchr(url + strlen(remote->url) + 1, '/');
while (ep) {
*ep = 0;
slot = get_active_slot();