From: hniksic Date: Sun, 17 Dec 2000 18:12:02 +0000 (-0800) Subject: [svn] Include where h_errno is used. Likewise for and errno. X-Git-Tag: v1.13~2322 X-Git-Url: http://sjero.net/git/?p=wget;a=commitdiff_plain;h=2e8fc46b7b969039590758c4d0542dd72798e15f [svn] Include where h_errno is used. Likewise for and errno. From . --- diff --git a/src/ChangeLog b/src/ChangeLog index a7181c0c..716a92d8 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,18 @@ +2000-12-17 Hrvoje Niksic + + * mswindows.c: Include . + + * gen_sslfunc.c: Include . + + * ftp-basic.c: Don't attempt to declare errno or h_errno because + they're not used. + + * main.c: Include because errno is used. + + * ftp.c: Ditto. + + * http.c: Include for h_errno. + 2000-12-13 Hrvoje Niksic * html-parse.c (advance_declaration): MSVC assert() chokes on diff --git a/src/ftp-basic.c b/src/ftp-basic.c index 8f6f25e1..d6d7c5a9 100644 --- a/src/ftp-basic.c +++ b/src/ftp-basic.c @@ -43,13 +43,6 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include "host.h" #include "ftp.h" -#ifndef errno -extern int errno; -#endif -#ifndef h_errno -extern int h_errno; -#endif - char ftp_last_respline[128]; diff --git a/src/ftp.c b/src/ftp.c index 2b9eb0f2..e28f4596 100644 --- a/src/ftp.c +++ b/src/ftp.c @@ -33,6 +33,9 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include #include #include +#ifndef WINDOWS +# include /* for h_errno */ +#endif #include "wget.h" #include "utils.h" diff --git a/src/gen_sslfunc.c b/src/gen_sslfunc.c index 44ff5022..8b64b581 100644 --- a/src/gen_sslfunc.c +++ b/src/gen_sslfunc.c @@ -18,19 +18,29 @@ along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include + #ifdef HAVE_SSL + +#include +#include +#include + #include #include #include #include #include #include -#include + #define SSL_ERR_CTX_CREATION -2 -#include + #include "wget.h" #include "connect.h" +#ifndef errno +extern int errno; +#endif + /* #### Shouldn't this be static? --hniksic */ int verify_callback PARAMS ((int, X509_STORE_CTX *)); diff --git a/src/http.c b/src/http.c index 676fef5b..8f0e86d7 100644 --- a/src/http.c +++ b/src/http.c @@ -46,6 +46,8 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #ifdef WINDOWS # include +#else +# include /* for h_errno */ #endif #include "wget.h" diff --git a/src/main.c b/src/main.c index 221ac5ae..7db0ba02 100644 --- a/src/main.c +++ b/src/main.c @@ -39,6 +39,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ # include #endif /* HAVE_LOCALE_H */ #endif /* HAVE_NLS */ +#include #define OPTIONS_DEFINED_HERE /* for options.h */ diff --git a/src/mswindows.c b/src/mswindows.c index bf09b095..e68d8522 100644 --- a/src/mswindows.c +++ b/src/mswindows.c @@ -26,10 +26,15 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include #include #include +#include #include "wget.h" #include "url.h" +#ifndef errno +extern int errno; +#endif + char *argv0; /* Defined in log.c. */ diff --git a/src/recur.c b/src/recur.c index 98c55970..21bb40b0 100644 --- a/src/recur.c +++ b/src/recur.c @@ -44,6 +44,10 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include "host.h" #include "hash.h" +#ifndef errno +extern int errno; +#endif + extern char *version_string; #define ROBOTS_FILENAME "robots.txt" diff --git a/src/retr.c b/src/retr.c index a334cea5..3334ced8 100644 --- a/src/retr.c +++ b/src/retr.c @@ -44,6 +44,10 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include "connect.h" #include "hash.h" +#ifndef errno +extern int errno; +#endif + #ifdef WINDOWS LARGE_INTEGER internal_time; #else