]> git.ipfire.org Git - thirdparty/git.git/commitdiff
am: change safe_to_abort()'s not rewinding error into a warning
authorStephan Beyer <s-beyer@gmx.net>
Wed, 7 Dec 2016 21:51:30 +0000 (22:51 +0100)
committerJunio C Hamano <gitster@pobox.com>
Thu, 8 Dec 2016 17:09:44 +0000 (09:09 -0800)
The error message tells the user that something went terribly wrong
and the --abort could not be performed. But the --abort is performed,
only without rewinding. By simply changing the error into a warning,
we indicate the user that she must not try something like
"git am --abort --force", instead she just has to check the HEAD.

Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/am.c

index 7cf40e6f2796f641b5ca075d9c93b54a1b33ff9f..826f18ba12d9c58ceb3e8d6998412c234b33bcfe 100644 (file)
@@ -2134,7 +2134,7 @@ static int safe_to_abort(const struct am_state *state)
        if (!oidcmp(&head, &abort_safety))
                return 1;
 
-       error(_("You seem to have moved HEAD since the last 'am' failure.\n"
+       warning(_("You seem to have moved HEAD since the last 'am' failure.\n"
                "Not rewinding to ORIG_HEAD"));
 
        return 0;