]> granicus.if.org Git - curl/commitdiff
imap.c: Fixed compilation warning with /Wall enabled
authorSteve Holme <steve_holme@hotmail.com>
Sat, 19 Mar 2016 11:01:36 +0000 (11:01 +0000)
committerSteve Holme <steve_holme@hotmail.com>
Sat, 19 Mar 2016 11:01:36 +0000 (11:01 +0000)
warning C4701: potentially uninitialized local variable 'size' used

Technically this can't happen, as the usage of 'size' is protected by
'if(parsed)' and 'parsed' is only set after 'size' has been parsed.

Anyway, lets keep the compiler happy.

lib/imap.c

index 0339add48bf5daf9d23665429ec116c23d9c4eac..a3d2cad22411e3c4fa7e61e921c5d9ac9e2b8ca9 100644 (file)
@@ -1102,7 +1102,7 @@ static CURLcode imap_state_fetch_resp(struct connectdata *conn, int imapcode,
   struct pingpong *pp = &imapc->pp;
   const char *ptr = data->state.buffer;
   bool parsed = FALSE;
-  curl_off_t size;
+  curl_off_t size = 0;
 
   (void)instate; /* no use for this yet */