diff options
author | Kaartic Sivaraam <kaartic.sivaraam@gmail.com> | 2017-11-14 12:42:59 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-11-15 03:43:29 +0100 |
commit | 662a4c8a097248a3c08a671866ecf37743f3ca4d (patch) | |
tree | 90b49dd44b8fe45ee56aa974d92884318eadc888 /builtin | |
parent | branch: correctly reject refs/heads/{-dash,HEAD} (diff) | |
download | git-662a4c8a097248a3c08a671866ecf37743f3ca4d.tar.xz git-662a4c8a097248a3c08a671866ecf37743f3ca4d.zip |
builtin/branch: remove redundant check for HEAD
The lower level code has been made to handle this case for the
sake of consistency. This has made this check redundant.
So, remove the redundant check.
Signed-off-by: Kaartic Sivaraam <kaartic.sivaraam@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/branch.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/builtin/branch.c b/builtin/branch.c index e5bbfb4a17..945790b60b 100644 --- a/builtin/branch.c +++ b/builtin/branch.c @@ -793,9 +793,6 @@ int cmd_branch(int argc, const char **argv, const char *prefix) } else if (argc > 0 && argc <= 2) { struct branch *branch = branch_get(argv[0]); - if (!strcmp(argv[0], "HEAD")) - die(_("it does not make sense to create 'HEAD' manually")); - if (!branch) die(_("no such branch '%s'"), argv[0]); |