Skip to content

Commit

Permalink
[PATCH] Fix symbolic ref validation
Browse files Browse the repository at this point in the history
Use the correct buffer when validating 'ref: refs/...'

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
  • Loading branch information
Jonas Fonseca authored and Junio C Hamano committed Oct 5, 2005
1 parent d6e548d commit 85912b0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion refs.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ int validate_symref(const char *path)
len -= 4;
while (len && isspace(*buf))
buf++, len--;
if (len >= 5 && !memcmp("refs/", buffer, 5))
if (len >= 5 && !memcmp("refs/", buf, 5))
return 0;
return -1;
}
Expand Down

0 comments on commit 85912b0

Please sign in to comment.