diff options
Diffstat (limited to 'sha1_name.c')
-rw-r--r-- | sha1_name.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/sha1_name.c b/sha1_name.c index 3820f28ae7..416a673d68 100644 --- a/sha1_name.c +++ b/sha1_name.c @@ -1033,14 +1033,15 @@ int interpret_branch_name(const char *name, struct strbuf *buf) * points to something different than a branch. */ if (!upstream) - return error(_("HEAD does not point to a branch")); + die(_("HEAD does not point to a branch")); if (!upstream->merge || !upstream->merge[0]->dst) { if (!ref_exists(upstream->refname)) - return error(_("No such branch: '%s'"), cp); - if (!upstream->merge) - return error(_("No upstream configured for branch '%s'"), - upstream->name); - return error( + die(_("No such branch: '%s'"), cp); + if (!upstream->merge) { + die(_("No upstream configured for branch '%s'"), + upstream->name); + } + die( _("Upstream branch '%s' not stored as a remote-tracking branch"), upstream->merge[0]->src); } |