Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'remote-curl.c')
-rw-r--r--remote-curl.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/remote-curl.c b/remote-curl.c
index 6ec5352435..e11e619d0d 100644
--- a/remote-curl.c
+++ b/remote-curl.c
@@ -351,6 +351,8 @@ static struct discovery *discover_refs(const char *service, int for_push)
* pkt-line matches our request.
*/
line = packet_read_line_buf(&last->buf, &last->len, NULL);
+ if (!line)
+ die("invalid server response; expected service, got flush packet");
strbuf_reset(&exp);
strbuf_addf(&exp, "# service=%s", service);