Revert "We do not like "HEAD" as a new branch name"
This reverts ee34518d62
commit.
This commit is contained in:
parent
8872f27b87
commit
f7087e2e7c
5
refs.c
5
refs.c
@ -347,11 +347,6 @@ int check_ref_format(const char *ref)
|
|||||||
if (!ch) {
|
if (!ch) {
|
||||||
if (level < 2)
|
if (level < 2)
|
||||||
return -1; /* at least of form "heads/blah" */
|
return -1; /* at least of form "heads/blah" */
|
||||||
|
|
||||||
/* do not allow ref name to end in "HEAD" */
|
|
||||||
if (cp - ref > 4 && !strcmp(cp - 4, "HEAD"))
|
|
||||||
return -1;
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user