From c514a2a89aa1c1e06b70405eedb4e1f70b27fd10 Mon Sep 17 00:00:00 2001 From: Gisle Vanem Date: Mon, 26 Feb 2007 04:24:26 +0000 Subject: [PATCH] Removed inclusion of and in .c-files since they're already included through "setup.h". --- lib/connect.c | 12 +++++------- lib/dict.c | 6 ------ lib/easy.c | 7 ------- lib/file.c | 6 ------ lib/formdata.c | 3 --- lib/ftp.c | 9 +++------ lib/gtls.c | 3 --- lib/hostares.c | 3 --- lib/hostasyn.c | 3 --- lib/hostip.c | 3 --- lib/hostip4.c | 3 --- lib/hostip6.c | 3 --- lib/hostsyn.c | 3 --- lib/hostthre.c | 3 --- lib/http.c | 6 ------ lib/inet_ntop.c | 3 --- lib/inet_pton.c | 3 --- lib/ldap.c | 8 +------- lib/mprintf.c | 1 - lib/multi.c | 4 +--- lib/netrc.c | 3 --- lib/nss.c | 3 --- lib/select.c | 3 --- lib/sendf.c | 4 ---- lib/ssh.c | 14 ++------------ lib/sslgen.c | 4 +--- lib/ssluse.c | 3 --- lib/telnet.c | 9 +-------- lib/tftp.c | 9 +-------- lib/transfer.c | 9 +-------- lib/url.c | 9 ++------- 31 files changed, 18 insertions(+), 144 deletions(-) diff --git a/lib/connect.c b/lib/connect.c index 14e2ff038..a18a335af 100644 --- a/lib/connect.c +++ b/lib/connect.c @@ -28,9 +28,6 @@ #ifdef HAVE_SYS_TIME_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif @@ -59,9 +56,9 @@ #include #endif #ifdef HAVE_STDLIB_H -#include /* required for free() prototype, without it, this crashes - on macos 68K */ -#endif +#include /* required for free() prototype, without it, this crashes */ +#endif /* on macos 68K */ + #if (defined(HAVE_FIONBIO) && defined(__NOVELL_LIBC__)) #include #endif @@ -74,7 +71,8 @@ #include #endif -#endif +#endif /* !WIN32 */ + #include #include #include diff --git a/lib/dict.c b/lib/dict.c index d6443f4b9..c302cd034 100644 --- a/lib/dict.c +++ b/lib/dict.c @@ -31,12 +31,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif #ifdef WIN32 #include diff --git a/lib/easy.c b/lib/easy.c index 1ada99c3d..d86f7cde5 100644 --- a/lib/easy.c +++ b/lib/easy.c @@ -29,13 +29,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif - #include #include "strequal.h" diff --git a/lib/file.c b/lib/file.c index b247a7736..3fc1663d1 100644 --- a/lib/file.c +++ b/lib/file.c @@ -30,12 +30,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif #ifdef WIN32 #include diff --git a/lib/formdata.c b/lib/formdata.c index f10c6c70e..a5118b389 100644 --- a/lib/formdata.c +++ b/lib/formdata.c @@ -112,9 +112,6 @@ Content-Disposition: form-data; name="FILECONTENT" #include #include #include -#ifdef HAVE_SYS_STAT_H -#include -#endif #if defined(HAVE_LIBGEN_H) && defined(HAVE_BASENAME) #include #endif diff --git a/lib/ftp.c b/lib/ftp.c index 8328315dc..8c54f7274 100644 --- a/lib/ftp.c +++ b/lib/ftp.c @@ -34,13 +34,10 @@ #include #endif -#ifdef WIN32 - -#else /* probably some kind of unix */ +#ifndef WIN32 #ifdef HAVE_SYS_SOCKET_H #include #endif -#include #ifdef HAVE_NETINET_IN_H #include #endif @@ -57,7 +54,7 @@ #include #include #endif -#endif +#endif /* !WIN32 */ #if (defined(NETWARE) && defined(__NOVELL_LIBC__)) #undef in_addr_t @@ -3024,7 +3021,7 @@ CURLcode Curl_ftp_done(struct connectdata *conn, CURLcode status, bool premature ftpc->ctl_valid = was_ctl_valid; break; } - /* until we cope better with prematurely ended requests, let them + /* until we cope better with prematurely ended requests, let them * fallback as if in complete failure */ default: /* by default, an error means the control connection is wedged and should not be used anymore */ diff --git a/lib/gtls.c b/lib/gtls.c index f8c103450..3413a0709 100644 --- a/lib/gtls.c +++ b/lib/gtls.c @@ -37,9 +37,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/hostares.c b/lib/hostares.c index 1eb2aea2b..c9fbcc6de 100644 --- a/lib/hostares.c +++ b/lib/hostares.c @@ -28,9 +28,6 @@ #ifdef NEED_MALLOC_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/hostasyn.c b/lib/hostasyn.c index 3df147910..355638604 100644 --- a/lib/hostasyn.c +++ b/lib/hostasyn.c @@ -28,9 +28,6 @@ #ifdef NEED_MALLOC_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/hostip.c b/lib/hostip.c index b27475188..399ac53e5 100644 --- a/lib/hostip.c +++ b/lib/hostip.c @@ -28,9 +28,6 @@ #ifdef NEED_MALLOC_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/hostip4.c b/lib/hostip4.c index 5c0c8841d..3b040a48f 100644 --- a/lib/hostip4.c +++ b/lib/hostip4.c @@ -29,9 +29,6 @@ #ifdef NEED_MALLOC_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/hostip6.c b/lib/hostip6.c index d69a4c658..777b1e319 100644 --- a/lib/hostip6.c +++ b/lib/hostip6.c @@ -28,9 +28,6 @@ #ifdef NEED_MALLOC_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/hostsyn.c b/lib/hostsyn.c index 2f816b858..dcca62e4e 100644 --- a/lib/hostsyn.c +++ b/lib/hostsyn.c @@ -28,9 +28,6 @@ #ifdef NEED_MALLOC_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/hostthre.c b/lib/hostthre.c index 9c8942a28..bd7a483c2 100644 --- a/lib/hostthre.c +++ b/lib/hostthre.c @@ -29,9 +29,6 @@ #ifdef NEED_MALLOC_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/http.c b/lib/http.c index 16c59fb87..b4a62f496 100644 --- a/lib/http.c +++ b/lib/http.c @@ -30,12 +30,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif #ifdef WIN32 #include diff --git a/lib/inet_ntop.c b/lib/inet_ntop.c index 8ff428192..a05689adb 100644 --- a/lib/inet_ntop.c +++ b/lib/inet_ntop.c @@ -25,9 +25,6 @@ #ifdef HAVE_SYS_PARAM_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/inet_pton.c b/lib/inet_pton.c index edffeabca..192d0624a 100644 --- a/lib/inet_pton.c +++ b/lib/inet_pton.c @@ -23,9 +23,6 @@ #ifdef HAVE_SYS_PARAM_H #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/ldap.c b/lib/ldap.c index 3e1144d4f..991204fd0 100644 --- a/lib/ldap.c +++ b/lib/ldap.c @@ -30,12 +30,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif #ifdef NEED_MALLOC_H #include #endif @@ -115,7 +109,7 @@ #undef HAVE_LIBDL #endif -/* +/* * We use this ZERO_NULL to avoid picky compiler warnings, * when assigning a NULL pointer to a function pointer var. */ diff --git a/lib/mprintf.c b/lib/mprintf.c index 3224521b0..55a6f6295 100644 --- a/lib/mprintf.c +++ b/lib/mprintf.c @@ -31,7 +31,6 @@ #include "setup.h" -#include #include #include #include diff --git a/lib/multi.c b/lib/multi.c index e55cb6994..c04cad142 100644 --- a/lib/multi.c +++ b/lib/multi.c @@ -22,12 +22,10 @@ ***************************************************************************/ #include "setup.h" + #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/netrc.c b/lib/netrc.c index 54d175989..da366fb6b 100644 --- a/lib/netrc.c +++ b/lib/netrc.c @@ -27,9 +27,6 @@ #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_UNISTD_H #include #endif diff --git a/lib/nss.c b/lib/nss.c index afeb2ffb9..652d9f1f7 100644 --- a/lib/nss.c +++ b/lib/nss.c @@ -31,9 +31,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/select.c b/lib/select.c index 12f34bcc8..4f8878401 100644 --- a/lib/select.c +++ b/lib/select.c @@ -25,9 +25,6 @@ #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SELECT_H #include #endif diff --git a/lib/sendf.c b/lib/sendf.c index 5d8c191d6..bf9ee490a 100644 --- a/lib/sendf.c +++ b/lib/sendf.c @@ -28,10 +28,6 @@ #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif - #ifdef HAVE_SYS_SOCKET_H #include /* required for send() & recv() prototypes */ #endif diff --git a/lib/ssh.c b/lib/ssh.c index d002173ab..1846945a7 100644 --- a/lib/ssh.c +++ b/lib/ssh.c @@ -44,24 +44,14 @@ #include #endif -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif - #ifdef HAVE_TIME_H #include #endif -#ifdef WIN32 - -#else /* probably some kind of unix */ +#ifndef WIN32 #ifdef HAVE_SYS_SOCKET_H #include #endif -#include #ifdef HAVE_NETINET_IN_H #include #endif @@ -78,7 +68,7 @@ #include #include #endif -#endif +#endif /* !WIN32 */ #if (defined(NETWARE) && defined(__NOVELL_LIBC__)) #undef in_addr_t diff --git a/lib/sslgen.c b/lib/sslgen.c index 6b1de1e3c..6bf240395 100644 --- a/lib/sslgen.c +++ b/lib/sslgen.c @@ -38,12 +38,10 @@ */ #include "setup.h" + #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/ssluse.c b/lib/ssluse.c index 6ef57853a..5bcc3a1e3 100644 --- a/lib/ssluse.c +++ b/lib/ssluse.c @@ -36,9 +36,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif #ifdef HAVE_SYS_SOCKET_H #include #endif diff --git a/lib/telnet.c b/lib/telnet.c index 74467ec86..756f358f4 100644 --- a/lib/telnet.c +++ b/lib/telnet.c @@ -30,12 +30,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif #if defined(WIN32) #include @@ -65,8 +59,7 @@ #include #endif - -#endif +#endif /* WIN32 */ #include "urldata.h" #include diff --git a/lib/tftp.c b/lib/tftp.c index 493725a23..bc17974ad 100644 --- a/lib/tftp.c +++ b/lib/tftp.c @@ -30,12 +30,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif #if defined(WIN32) #include @@ -65,8 +59,7 @@ #include #endif - -#endif +#endif /* WIN32 */ #include "urldata.h" #include diff --git a/lib/transfer.c b/lib/transfer.c index 324aba260..8e6f5e19f 100644 --- a/lib/transfer.c +++ b/lib/transfer.c @@ -29,13 +29,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif - #include #include "strtoofft.h" @@ -81,7 +74,7 @@ #error "We can't compile without socket() support!" #endif -#endif +#endif /* WIN32 */ #include "urldata.h" #include diff --git a/lib/url.c b/lib/url.c index e777d2a1f..64a145cdb 100644 --- a/lib/url.c +++ b/lib/url.c @@ -30,12 +30,6 @@ #include #include #include -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_STAT_H -#include -#endif #include #ifdef WIN32 @@ -78,7 +72,8 @@ #ifndef HAVE_SOCKET #error "We can't compile without socket() support!" #endif -#endif + +#endif /* WIN32 */ #ifdef USE_LIBIDN #include