]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Initialize fd values in tor_port_check_forwarding to -1
authorNick Mathewson <nickm@torproject.org>
Fri, 1 Oct 2010 22:14:17 +0000 (18:14 -0400)
committerNick Mathewson <nickm@torproject.org>
Fri, 1 Oct 2010 22:14:17 +0000 (18:14 -0400)
src/common/util.c

index ef9c5bb624f92b35b44d956fcfe6942a6e37ac7d..b5a3ade2bd1facc4052ed55019cb4b118ed2cece 100644 (file)
@@ -3226,7 +3226,7 @@ tor_check_port_forwarding(const char *filename, int dir_port, int or_port,
   /* Start the child, if it is not already running */
   if (-1 == child_pid &&
       time_to_run_helper < now) {
-    int fd_out, fd_err;
+    int fd_out=-1, fd_err=-1;
 
     /* Assume tor-fw-helper will succeed, start it later*/
     time_to_run_helper = now + TIME_TO_EXEC_FWHELPER_SUCCESS;