]> sjero.net Git - wget/commitdiff
[svn] Fix compilation under pre-C99 compilers.
authorhniksic <devnull@localhost>
Wed, 5 Nov 2003 21:33:46 +0000 (13:33 -0800)
committerhniksic <devnull@localhost>
Wed, 5 Nov 2003 21:33:46 +0000 (13:33 -0800)
src/ChangeLog
src/connect.c

index e953555801734b25f6bb88dd121e65b14172d69f..330ec2b243f54a033ea47572e17216f05068ee44 100644 (file)
@@ -1,3 +1,7 @@
+2003-11-05  Hrvoje Niksic  <hniksic@xemacs.org>
+
+       * connect.c (bindport): Fix compilation under pre-C99 compilers.
+
 2003-11-05  Hrvoje Niksic  <hniksic@xemacs.org>
 
        * connect.c (connect_to_ip): More compact error checking.
index c65868d89399f0c95dfa29f2c16e37a054bd82cb..62ce2af9a86f2f4be2153f286354791dc958d84e 100644 (file)
@@ -397,7 +397,6 @@ bindport (const ip_address *bind_address, int *port, int *local_sock)
   int family = AF_INET;
   struct sockaddr_storage ss;
   struct sockaddr *sa = (struct sockaddr *)&ss;
-  xzero (ss);
 
   /* For setting options with setsockopt. */
   int setopt_val = 1;
@@ -423,6 +422,7 @@ bindport (const ip_address *bind_address, int *port, int *local_sock)
 # endif
 #endif
 
+  xzero (ss);
   sockaddr_set_data (sa, bind_address, *port);
   if (bind (sock, sa, sockaddr_size (sa)) < 0)
     {