]> granicus.if.org Git - curl/commitdiff
Fix compiler warning: local variable may be used without having been initialized
authorYang Tse <yangsita@gmail.com>
Wed, 3 Oct 2007 16:26:56 +0000 (16:26 +0000)
committerYang Tse <yangsita@gmail.com>
Wed, 3 Oct 2007 16:26:56 +0000 (16:26 +0000)
lib/select.c

index 28bb141b16583ae2f15a519ee22dd69f7f981651..3f81ba180d4fe1abd0d9fe4a5bc9f7f00268d14f 100644 (file)
@@ -183,7 +183,7 @@ int Curl_socket_ready(curl_socket_t readfd, curl_socket_t writefd,
   fd_set fds_err;
   curl_socket_t maxfd;
 #endif
-  struct timeval initial_tv;
+  struct timeval initial_tv = {0,0};
   int pending_ms = 0;
   int error;
   int r;
@@ -358,7 +358,7 @@ int Curl_poll(struct pollfd ufds[], unsigned int nfds, int timeout_ms)
   fd_set fds_err;
   curl_socket_t maxfd;
 #endif
-  struct timeval initial_tv;
+  struct timeval initial_tv = {0,0};
   bool fds_none = TRUE;
   unsigned int i;
   int pending_ms = 0;