From: Ramsay Jones Date: Wed, 21 Nov 2012 19:08:51 +0000 (+0000) Subject: remote-curl.c: Fix a compiler warning X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=377115493a9f3700f9b71de9ac86464b8bfd3fa2;p=git.git remote-curl.c: Fix a compiler warning In particular, gcc issues an "'gzip_size' might be used uninitialized" warning (-Wuninitialized). However, this warning is a false positive, since the 'gzip_size' variable would not, in fact, be used uninitialized. In order to suppress the warning, we simply initialise the variable to zero in it's declaration. Signed-off-by: Ramsay Jones Signed-off-by: Junio C Hamano --- diff --git a/remote-curl.c b/remote-curl.c index fac2befd8..5b1bb1991 100644 --- a/remote-curl.c +++ b/remote-curl.c @@ -413,7 +413,7 @@ static int post_rpc(struct rpc_state *rpc) struct curl_slist *headers = NULL; int use_gzip = rpc->gzip_request; char *gzip_body = NULL; - size_t gzip_size; + size_t gzip_size = 0; int err, large_request = 0; /* Try to load the entire request, if we can fit it into the