]> git.ipfire.org Git - thirdparty/git.git/commitdiff
push: do not pretend to return `int` from `die_push_simple()`
authorJohannes Schindelin <johannes.schindelin@gmx.de>
Mon, 30 Sep 2019 09:55:31 +0000 (02:55 -0700)
committerJunio C Hamano <gitster@pobox.com>
Thu, 3 Oct 2019 22:35:31 +0000 (07:35 +0900)
This function is marked as `NORETURN`, and it indeed does not want to
return anything. So let's not declare it with the return type `int`.
This fixes the following warning when building with MSVC:

C4646: function declared with 'noreturn' has non-void return type

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/push.c

index 021dd3b1e48979086de68a434d4eddbbeb074df3..d216270d5fa39f8122e1c7155327b7155f0e22e1 100644 (file)
@@ -143,8 +143,8 @@ static int push_url_of_remote(struct remote *remote, const char ***url_p)
        return remote->url_nr;
 }
 
-static NORETURN int die_push_simple(struct branch *branch,
-                                   struct remote *remote)
+static NORETURN void die_push_simple(struct branch *branch,
+                                    struct remote *remote)
 {
        /*
         * There's no point in using shorten_unambiguous_ref here,