diff options
Diffstat (limited to 'builtin/merge.c')
-rw-r--r-- | builtin/merge.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/merge.c b/builtin/merge.c index a068660d09..c371484ab6 100644 --- a/builtin/merge.c +++ b/builtin/merge.c @@ -1030,7 +1030,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix) branch = resolve_ref("HEAD", head, 0, &flag); if (branch && !prefixcmp(branch, "refs/heads/")) branch += 11; - if (is_null_sha1(head)) + if (!branch || is_null_sha1(head)) head_invalid = 1; git_config(git_merge_config, NULL); |