From: Junio C Hamano Date: Mon, 8 May 2006 22:44:06 +0000 (-0700) Subject: get_sha1() - fix infinite loop on nonexistent stage. X-Git-Tag: v1.4.0-rc1~156^2 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=e7cef45fbceab9558adce82a26b96f15af47772c;p=git.git get_sha1() - fix infinite loop on nonexistent stage. Signed-off-by: Junio C Hamano --- diff --git a/sha1_name.c b/sha1_name.c index ec5cd2c9e..dc6835520 100644 --- a/sha1_name.c +++ b/sha1_name.c @@ -498,6 +498,7 @@ int get_sha1(const char *name, unsigned char *sha1) memcpy(sha1, ce->sha1, 20); return 0; } + pos++; } return -1; }