diff options
author | Junio C Hamano <gitster@pobox.com> | 2012-02-06 08:58:43 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2012-02-06 08:58:43 +0100 |
commit | f2120eb4db3e3e3f9a336eb04fdc2319d7421536 (patch) | |
tree | da17eb49578d0413168d71931a840084ea6f6657 /remote-curl.c | |
parent | Merge branch 'jc/maint-log-first-parent-pathspec' into maint (diff) | |
parent | remote-curl: Fix push status report when all branches fail (diff) | |
download | git-f2120eb4db3e3e3f9a336eb04fdc2319d7421536.tar.xz git-f2120eb4db3e3e3f9a336eb04fdc2319d7421536.zip |
Merge branch 'sp/smart-http-failure-to-push' into maint
* sp/smart-http-failure-to-push:
remote-curl: Fix push status report when all branches fail
Diffstat (limited to 'remote-curl.c')
-rw-r--r-- | remote-curl.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/remote-curl.c b/remote-curl.c index bcbc7fba4e..d159fe7f34 100644 --- a/remote-curl.c +++ b/remote-curl.c @@ -807,7 +807,7 @@ static int push(int nr_spec, char **specs) static void parse_push(struct strbuf *buf) { char **specs = NULL; - int alloc_spec = 0, nr_spec = 0, i; + int alloc_spec = 0, nr_spec = 0, i, ret; do { if (!prefixcmp(buf->buf, "push ")) { @@ -824,12 +824,13 @@ static void parse_push(struct strbuf *buf) break; } while (1); - if (push(nr_spec, specs)) - exit(128); /* error already reported */ - + ret = push(nr_spec, specs); printf("\n"); fflush(stdout); + if (ret) + exit(128); /* error already reported */ + free_specs: for (i = 0; i < nr_spec; i++) free(specs[i]); |