You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by gs...@apache.org on 2001/02/10 14:05:30 UTC
cvs commit: httpd-2.0/server log.c main.c rfc1413.c scoreboard.c util.c util_date.c util_debug.c util_script.c util_xml.c vhost.c
gstein 01/02/10 05:05:30
Modified: include util_filter.h
modules/aaa mod_access.c mod_auth.c mod_auth_digest.c
modules/dav/fs lock.c
modules/dav/main mod_dav.c util.c
modules/filters mod_include.c
modules/generators mod_autoindex.c
modules/http http_protocol.c http_request.c
modules/loggers mod_log_config.c
modules/mappers mod_alias.c mod_imap.c mod_negotiation.c
mod_rewrite.c mod_rewrite.h
server log.c main.c rfc1413.c scoreboard.c util.c
util_date.c util_debug.c util_script.c util_xml.c
vhost.c
Log:
Clean up some of the includes:
- explicitly include apr_lib.h since ap_config.h doesn't
- use apr_want.h where possible
- use APR_HAVE_ where possible
- remove some unneeded includes
Revision Changes Path
1.44 +8 -7 httpd-2.0/include/util_filter.h
Index: util_filter.h
===================================================================
RCS file: /home/cvs/httpd-2.0/include/util_filter.h,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -u -r1.43 -r1.44
--- util_filter.h 2001/02/09 22:57:49 1.43
+++ util_filter.h 2001/02/10 13:05:21 1.44
@@ -55,17 +55,18 @@
#ifndef AP_FILTER_H
#define AP_FILTER_H
-#ifdef __cplusplus
-extern "C" {
-#endif
+#include "apr.h"
+#include "apr_buckets.h"
+
+#include "httpd.h"
-#ifdef APR_HAVE_STDARG_H
+#if APR_HAVE_STDARG_H
#include <stdarg.h>
#endif
-#include "httpd.h"
-#include "apr.h"
-#include "apr_buckets.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
/**
* @package Apache filter library
1.27 +8 -9 httpd-2.0/modules/aaa/mod_access.c
Index: mod_access.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/aaa/mod_access.c,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -u -r1.26 -r1.27
--- mod_access.c 2001/02/08 07:43:58 1.26
+++ mod_access.c 2001/02/10 13:05:22 1.27
@@ -65,23 +65,22 @@
#include "apr_strings.h"
#include "apr_network_io.h"
+#include "apr_lib.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#include "ap_config.h"
#include "httpd.h"
#include "http_core.h"
#include "http_config.h"
#include "http_log.h"
#include "http_request.h"
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
-#ifdef HAVE_NETINET_IN_H
+
+#if APR_HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
-
-#ifdef HAVE_ARPA_INET_H
+#if APR_HAVE_ARPA_INET_H
#include <arpa/inet.h>
#endif
1.29 +3 -1 httpd-2.0/modules/aaa/mod_auth.c
Index: mod_auth.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/aaa/mod_auth.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -u -r1.28 -r1.29
--- mod_auth.c 2001/02/08 07:43:58 1.28
+++ mod_auth.c 2001/02/10 13:05:22 1.29
@@ -70,9 +70,11 @@
* no control is passed along.
*/
-#include "ap_config.h"
#include "apr_strings.h"
#include "apr_md5.h"
+#include "apr_lib.h"
+
+#include "ap_config.h"
#include "httpd.h"
#include "http_config.h"
#include "http_core.h"
1.34 +0 -1 httpd-2.0/modules/aaa/mod_auth_digest.c
Index: mod_auth_digest.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/aaa/mod_auth_digest.c,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -u -r1.33 -r1.34
--- mod_auth_digest.c 2001/02/08 14:39:31 1.33
+++ mod_auth_digest.c 2001/02/10 13:05:22 1.34
@@ -101,7 +101,6 @@
#endif
#include "httpd.h"
#include "http_config.h"
-#include "http_conf_globals.h"
#include "http_core.h"
#include "http_request.h"
#include "http_log.h"
1.15 +3 -0 httpd-2.0/modules/dav/fs/lock.c
Index: lock.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/dav/fs/lock.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -u -r1.14 -r1.15
--- lock.c 2001/02/08 07:43:59 1.14
+++ lock.c 2001/02/10 13:05:22 1.15
@@ -61,6 +61,9 @@
#include "apr_file_io.h"
#include "apr_uuid.h"
+#define APR_WANT_MEMFUNC
+#include "apr_want.h"
+
#include "httpd.h"
#include "http_log.h"
1.47 +5 -1 httpd-2.0/modules/dav/main/mod_dav.c
Index: mod_dav.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/dav/main/mod_dav.c,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -u -r1.46 -r1.47
--- mod_dav.c 2001/02/08 16:38:11 1.46
+++ mod_dav.c 2001/02/10 13:05:23 1.47
@@ -80,6 +80,11 @@
** so that we can keep the connection open.
*/
+#include "apr_strings.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#include "httpd.h"
#include "http_config.h"
#include "http_core.h"
@@ -88,7 +93,6 @@
#include "http_protocol.h"
#include "http_request.h"
#include "util_script.h"
-#include "apr_strings.h"
#include "mod_dav.h"
1.20 +5 -2 httpd-2.0/modules/dav/main/util.c
Index: util.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/dav/main/util.c,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -u -r1.19 -r1.20
--- util.c 2001/02/08 07:44:00 1.19
+++ util.c 2001/02/10 13:05:23 1.20
@@ -57,6 +57,11 @@
** - various utilities, repository-independent
*/
+#include "apr_strings.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#include "mod_dav.h"
#include "http_request.h"
@@ -64,8 +69,6 @@
#include "http_vhost.h"
#include "http_log.h"
#include "http_protocol.h"
-
-#include "apr_strings.h"
DAV_DECLARE(dav_error*) dav_new_error(apr_pool_t *p, int status,
int error_id, const char *desc)
1.96 +1 -0 httpd-2.0/modules/filters/mod_include.c
Index: mod_include.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/filters/mod_include.c,v
retrieving revision 1.95
retrieving revision 1.96
diff -u -u -r1.95 -r1.96
--- mod_include.c 2001/02/08 07:44:02 1.95
+++ mod_include.c 2001/02/10 13:05:24 1.96
@@ -69,6 +69,7 @@
#include "apr_thread_proc.h"
#include "apr_hash.h"
#include "apr_user.h"
+#include "apr_lib.h"
#define CORE_PRIVATE
1.57 +10 -9 httpd-2.0/modules/generators/mod_autoindex.c
Index: mod_autoindex.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/generators/mod_autoindex.c,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -u -r1.56 -r1.57
--- mod_autoindex.c 2001/02/08 07:44:02 1.56
+++ mod_autoindex.c 2001/02/10 13:05:24 1.57
@@ -64,9 +64,17 @@
*
* Adapted to Apache by rst.
*
- * Version sort added by Martin Pool <mb...@humbug.org.au>. */
+ * Version sort added by Martin Pool <mb...@humbug.org.au>.
+ */
#include "apr_strings.h"
+#include "apr_fnmatch.h"
+#include "apr_strings.h"
+#include "apr_lib.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#include "ap_config.h"
#include "httpd.h"
#include "http_config.h"
@@ -76,14 +84,7 @@
#include "http_log.h"
#include "http_main.h"
#include "util_script.h"
-#include "apr_fnmatch.h"
-#include "apr_strings.h"
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
+
module AP_MODULE_DECLARE_DATA autoindex_module;
1.295 +5 -5 httpd-2.0/modules/http/http_protocol.c
Index: http_protocol.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/http/http_protocol.c,v
retrieving revision 1.294
retrieving revision 1.295
diff -u -u -r1.294 -r1.295
--- http_protocol.c 2001/02/09 12:19:47 1.294
+++ http_protocol.c 2001/02/10 13:05:25 1.295
@@ -66,16 +66,13 @@
#include "apr.h"
#include "apr_strings.h"
#include "apr_buckets.h"
+#include "apr_lib.h"
#define APR_WANT_STDIO /* for sscanf */
#define APR_WANT_STRFUNC
#define APR_WANT_MEMFUNC
#include "apr_want.h"
-#if APR_HAVE_STDARG_H
-#include <stdarg.h>
-#endif
-
#define CORE_PRIVATE
#include "util_filter.h"
#include "ap_config.h"
@@ -94,7 +91,10 @@
#include "mod_core.h"
-#ifdef HAVE_UNISTD_H
+#if APR_HAVE_STDARG_H
+#include <stdarg.h>
+#endif
+#if APR_HAVE_UNISTD_H
#include <unistd.h>
#endif
1.87 +4 -1 httpd-2.0/modules/http/http_request.c
Index: http_request.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/http/http_request.c,v
retrieving revision 1.86
retrieving revision 1.87
diff -u -u -r1.86 -r1.87
--- http_request.c 2001/02/08 07:44:04 1.86
+++ http_request.c 2001/02/10 13:05:25 1.87
@@ -70,6 +70,9 @@
#include "apr_file_io.h"
#include "apr_fnmatch.h"
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#define CORE_PRIVATE
#include "ap_config.h"
#include "httpd.h"
@@ -84,7 +87,7 @@
#include "mod_core.h"
-#ifdef APR_HAVE_STDARG_H
+#if APR_HAVE_STDARG_H
#include <stdarg.h>
#endif
1.48 +9 -6 httpd-2.0/modules/loggers/mod_log_config.c
Index: mod_log_config.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/loggers/mod_log_config.c,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -u -r1.47 -r1.48
--- mod_log_config.c 2001/02/10 03:38:48 1.47
+++ mod_log_config.c 2001/02/10 13:05:26 1.48
@@ -179,24 +179,27 @@
*
* --- rst */
-#define DEFAULT_LOG_FORMAT "%h %l %u %t \"%r\" %>s %b"
-
#include "apr_strings.h"
+#include "apr_lib.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#include "ap_config.h"
#include "httpd.h"
#include "http_config.h"
#include "http_core.h" /* For REMOTE_NAME */
#include "http_log.h"
#include "http_protocol.h"
-#ifdef HAVE_UNISTD_H
+
+#if APR_HAVE_UNISTD_H
#include <unistd.h>
#endif
#ifdef HAVE_LIMITS_H
#include <limits.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
#endif
+
+#define DEFAULT_LOG_FORMAT "%h %l %u %t \"%r\" %>s %b"
module AP_MODULE_DECLARE_DATA config_log_module;
1.25 +6 -3 httpd-2.0/modules/mappers/mod_alias.c
Index: mod_alias.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/mappers/mod_alias.c,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -u -r1.24 -r1.25
--- mod_alias.c 2001/02/08 07:44:05 1.24
+++ mod_alias.c 2001/02/10 13:05:26 1.25
@@ -65,13 +65,16 @@
*/
#include "apr_strings.h"
+#include "apr_lib.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#include "ap_config.h"
#include "httpd.h"
#include "http_config.h"
#include "http_request.h"
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
+
typedef struct {
const char *real;
1.28 +5 -9 httpd-2.0/modules/mappers/mod_imap.c
Index: mod_imap.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/mappers/mod_imap.c,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -u -r1.27 -r1.28
--- mod_imap.c 2001/01/19 07:04:22 1.27
+++ mod_imap.c 2001/02/10 13:05:26 1.28
@@ -94,10 +94,11 @@
#include "apr.h"
#include "apr_strings.h"
+#include "apr_lib.h"
-#if APR_HAVE_STDIO_H
-#include <stdio.h> /* for sscanf() */
-#endif
+#define APR_WANT_STDIO /* for sscanf() */
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
#include "ap_config.h"
#include "httpd.h"
@@ -108,12 +109,7 @@
#include "http_main.h"
#include "http_log.h"
#include "util_script.h"
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
+
#define IMAP_MAGIC_TYPE "application/x-httpd-imap"
#define MAXVERTS 100
1.54 +5 -9 httpd-2.0/modules/mappers/mod_negotiation.c
Index: mod_negotiation.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/mappers/mod_negotiation.c,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -u -r1.53 -r1.54
--- mod_negotiation.c 2001/02/08 07:44:05 1.53
+++ mod_negotiation.c 2001/02/10 13:05:26 1.54
@@ -66,10 +66,11 @@
#include "apr.h"
#include "apr_strings.h"
#include "apr_file_io.h"
+#include "apr_lib.h"
-#if APR_HAVE_STDIO_H
-#include <stdio.h> /* for EOF */
-#endif
+#define APR_WANT_STDIO /* for EOF */
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
#include "ap_config.h"
#include "httpd.h"
@@ -79,12 +80,7 @@
#include "http_core.h"
#include "http_log.h"
#include "util_script.h"
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
+
#define MAP_FILE_MAGIC_TYPE "application/x-type-map"
1.68 +17 -20 httpd-2.0/modules/mappers/mod_rewrite.c
Index: mod_rewrite.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/mappers/mod_rewrite.c,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -u -r1.67 -r1.68
--- mod_rewrite.c 2001/02/08 07:44:05 1.67
+++ mod_rewrite.c 2001/02/10 13:05:26 1.68
@@ -88,6 +88,22 @@
** www.engelschall.com
*/
+#include "apr.h"
+#include "apr_strings.h"
+#include "apr_user.h"
+#include "apr_lib.h"
+
+#define APR_WANT_STRFUNC
+#define APR_WANT_IOVEC
+#include "apr_want.h"
+
+#if APR_HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+#if APR_HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+
#include "ap_config.h"
#include "httpd.h"
#include "http_config.h"
@@ -96,28 +112,9 @@
#include "http_log.h"
#include "http_protocol.h"
#include "mod_rewrite.h"
-#include "apr_strings.h"
-#include "apr_user.h"
-#if !defined(OS2) && !defined(WIN32)
+#if !defined(OS2) && !defined(WIN32) && !defined(BEOS)
#include "unixd.h"
-#endif
-
-#ifndef NO_WRITEV
-#ifndef NETWARE
-#ifdef HAVE_SYS_TYPES_H
-#include <sys/types.h>
-#endif
-#endif
-#if APR_HAVE_SYS_UIO_H
-#include <sys/uio.h>
-#endif
-#endif
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
#endif
/*
1.22 +18 -18 httpd-2.0/modules/mappers/mod_rewrite.h
Index: mod_rewrite.h
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/mappers/mod_rewrite.h,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -u -r1.21 -r1.22
--- mod_rewrite.h 2001/02/10 12:13:26 1.21
+++ mod_rewrite.h 2001/02/10 13:05:26 1.22
@@ -56,8 +56,8 @@
* University of Illinois, Urbana-Champaign.
*/
-#ifndef _MOD_REWRITE_H
-#define _MOD_REWRITE_H 1
+#ifndef MOD_REWRITE_H
+#define MOD_REWRITE_H 1
/*
** _ _ _
@@ -92,30 +92,32 @@
** www.engelschall.com
*/
+#include "apr.h"
+#define APR_WANT_STRFUNC
+#define APR_WANT_MEMFUNC
+#include "apr_want.h"
+
/* Include from the underlaying Unix system ... */
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif
-#ifdef APR_HAVE_STDARG_H
+#if APR_HAVE_STDARG_H
#include <stdarg.h>
#endif
-#ifdef HAVE_STDLIB_H
+#if APR_HAVE_STDLIB_H
#include <stdlib.h>
-#endif
-#ifdef HAVE_TIME_H
-#include <time.h>
#endif
-#ifdef HAVE_CTYPE_H
+#if APR_HAVE_CTYPE_H
#include <ctype.h>
#endif
-#ifndef NETWARE
+#if APR_HAVE_SYS_TYPES_H
#include <sys/types.h>
#endif
-/* are these needed anymore? rbb */
-#include <signal.h>
-#include <errno.h>
+#include "ap_config.h"
+
+#ifdef HAVE_TIME_H
+#include <time.h>
+#endif
+
/* Include from the Apache server ... */
#define CORE_PRIVATE
#include "httpd.h"
@@ -471,7 +473,5 @@
/* Bracketed expression handling */
static char *find_closing_bracket(char *s, int left, int right);
static char *find_char_in_brackets(char *s, int c, int left, int right);
-
-#endif /* _MOD_REWRITE_H */
-/*EOF*/
+#endif /* MOD_REWRITE_H */
1.85 +8 -10 httpd-2.0/server/log.c
Index: log.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/log.c,v
retrieving revision 1.84
retrieving revision 1.85
diff -u -u -r1.84 -r1.85
--- log.c 2001/02/08 07:44:18 1.84
+++ log.c 2001/02/10 13:05:27 1.85
@@ -68,13 +68,18 @@
#include "apr_strings.h"
#include "apr_errno.h"
#include "apr_thread_proc.h"
+#include "apr_lib.h"
-#if APR_HAVE_STDIO_H
-#include <stdio.h>
-#endif
+#define APR_WANT_STDIO
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#if APR_HAVE_STDARG_H
#include <stdarg.h>
#endif
+#if APR_HAVE_UNISTD_H
+#include <unistd.h>
+#endif
#define CORE_PRIVATE
@@ -84,13 +89,6 @@
#include "http_core.h"
#include "http_log.h"
#include "http_main.h"
-
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif
typedef struct {
char *t_name;
1.89 +3 -3 httpd-2.0/server/main.c
Index: main.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/main.c,v
retrieving revision 1.88
retrieving revision 1.89
diff -u -u -r1.88 -r1.89
--- main.c 2001/02/08 07:44:18 1.88
+++ main.c 2001/02/10 13:05:27 1.89
@@ -60,10 +60,10 @@
#include "apr_strings.h"
#include "apr_getopt.h"
#include "apr_general.h"
+#include "apr_lib.h"
-#if APR_HAVE_STDIO_H
-#include <stdio.h>
-#endif
+#define APR_WANT_STDIO
+#include "apr_want.h"
#define CORE_PRIVATE
#include "ap_config.h"
1.37 +4 -8 httpd-2.0/server/rfc1413.c
Index: rfc1413.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/rfc1413.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -u -r1.36 -r1.37
--- rfc1413.c 2001/02/08 07:44:19 1.36
+++ rfc1413.c 2001/02/10 13:05:28 1.37
@@ -82,17 +82,13 @@
#include "apr.h"
#include "apr_network_io.h"
#include "apr_strings.h"
+#include "apr_lib.h"
-#if APR_HAVE_STDIO_H
-#include <stdio.h>
-#endif
+#define APR_WANT_STDIO
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
#include "ap_config.h"
-
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif
-
#include "httpd.h" /* for server_rec, conn_rec, etc. */
#include "http_log.h" /* for aplog_error */
#include "rfc1413.h"
1.13 +7 -3 httpd-2.0/server/scoreboard.c
Index: scoreboard.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/scoreboard.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -u -r1.12 -r1.13
--- scoreboard.c 2001/02/10 03:03:17 1.12
+++ scoreboard.c 2001/02/10 13:05:28 1.13
@@ -56,8 +56,15 @@
* University of Illinois, Urbana-Champaign.
*/
+#include "apr.h"
#include "apr_strings.h"
#include "apr_portable.h"
+#include "apr_lib.h"
+
+#if APR_HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+
#include "ap_config.h"
#include "httpd.h"
#include "http_log.h"
@@ -67,9 +74,6 @@
#include "mpm.h"
#include "scoreboard.h"
-#ifdef HAVE_SYS_TYPES_H
-#include <sys/types.h>
-#endif
AP_DECLARE_DATA scoreboard *ap_scoreboard_image = NULL;
AP_DECLARE_DATA const char *ap_scoreboard_fname=NULL;
1.100 +11 -21 httpd-2.0/server/util.c
Index: util.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/util.c,v
retrieving revision 1.99
retrieving revision 1.100
diff -u -u -r1.99 -r1.100
--- util.c 2001/02/10 01:16:11 1.99
+++ util.c 2001/02/10 13:05:28 1.100
@@ -69,21 +69,23 @@
* #define DEBUG_CFG_LINES to trace every line read from the config files
*/
-#define CORE_PRIVATE
-
#include "apr.h"
#include "apr_strings.h"
+#include "apr_lib.h"
-#if APR_HAVE_STDIO_H
-#include <stdio.h> /* for EOF */
-#endif
-#if APR_HAVE_NETINET_IN_H
-#include <netinet/in.h>
+#define APR_WANT_STDIO
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
+#if APR_HAVE_UNISTD_H
+#include <unistd.h>
#endif
-#if APR_HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
+#if APR_HAVE_NETDB_H
+#include <netdb.h> /* for gethostbyname() */
#endif
+#define CORE_PRIVATE
+
#include "ap_config.h"
#include "apr_base64.h"
#include "httpd.h"
@@ -93,23 +95,11 @@
#include "http_config.h"
#include "util_ebcdic.h"
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif
-#ifdef HAVE_NETDB_H
-#include <netdb.h>
-#endif
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
#ifdef HAVE_PWD_H
#include <pwd.h>
#endif
#ifdef HAVE_GRP_H
#include <grp.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
#endif
/* A bunch of functions in util.c scan strings looking for certain characters.
1.17 +10 -6 httpd-2.0/server/util_date.c
Index: util_date.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/util_date.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -u -r1.16 -r1.17
--- util_date.c 2000/10/16 06:04:53 1.16
+++ util_date.c 2001/02/10 13:05:28 1.17
@@ -67,16 +67,20 @@
*
*/
+#include "apr.h"
+#include "apr_lib.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
+#if APR_HAVE_CTYPE_H
+#include <ctype.h>
+#endif
+
#define CORE_PRIVATE
#include "ap_config.h"
#include "util_date.h"
-#ifdef HAVE_CTYPE_H
-#include <ctype.h>
-#endif
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif
/*
* Compare a string to a mask
1.3 +22 -7 httpd-2.0/server/util_debug.c
Index: util_debug.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/util_debug.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -u -r1.2 -r1.3
--- util_debug.c 2000/06/24 19:31:41 1.2
+++ util_debug.c 2001/02/10 13:05:28 1.3
@@ -56,31 +56,46 @@
* University of Illinois, Urbana-Champaign.
*/
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#include "httpd.h"
#ifdef AP_DEBUG
# undef strchr
char *ap_strchr(char *s, int c)
-{ return strchr(s,c); }
+{
+ return strchr(s,c);
+}
const char *ap_strchr_c(const char *s, int c)
-{ return strchr(s,c); }
+{
+ return strchr(s,c);
+}
# undef strrchr
char *ap_strrchr(char *s, int c)
-{ return strrchr(s,c); }
+{
+ return strrchr(s,c);
+}
const char *ap_strrchr_c(const char *s, int c)
-{ return strrchr(s,c); }
+{
+ return strrchr(s,c);
+}
#undef strstr
char *ap_strstr(char *s, char *c)
-{ return strstr(s,c); }
+{
+ return strstr(s,c);
+}
const char *ap_strstr_c(const char *s, const char *c)
-{ return strstr(s,c); }
+{
+ return strstr(s,c);
+}
-#endif
+#endif /* AP_DEBUG */
1.54 +11 -13 httpd-2.0/server/util_script.c
Index: util_script.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/util_script.c,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -u -r1.53 -r1.54
--- util_script.c 2001/02/08 07:44:21 1.53
+++ util_script.c 2001/02/10 13:05:28 1.54
@@ -56,9 +56,19 @@
* University of Illinois, Urbana-Champaign.
*/
+#include "apr.h"
+#include "apr_lib.h"
+#include "apr_strings.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
+#if APR_HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
+
#define CORE_PRIVATE
#include "ap_config.h"
-#include "apr_strings.h"
#include "httpd.h"
#include "http_config.h"
#include "http_main.h"
@@ -69,18 +79,6 @@
#include "util_script.h"
#include "util_date.h" /* For parseHTTPdate() */
#include "util_ebcdic.h"
-#ifdef HAVE_STDLIB_H
-#include <stdlib.h>
-#endif
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
#ifdef OS2
#define INCL_DOS
1.14 +3 -3 httpd-2.0/server/util_xml.c
Index: util_xml.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/util_xml.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -u -r1.13 -r1.14
--- util_xml.c 2001/02/08 07:44:22 1.13
+++ util_xml.c 2001/02/10 13:05:29 1.14
@@ -63,9 +63,9 @@
#include "apr.h"
#include "apr_strings.h"
-#if APR_HAVE_STDIO_H
-#include <stdio.h> /* for fprintf(), sprintf() */
-#endif
+#define APR_WANT_STDIO /* for fprintf(), sprintf() */
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
#include "httpd.h"
#include "http_protocol.h"
1.54 +7 -17 httpd-2.0/server/vhost.c
Index: vhost.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/vhost.c,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -u -r1.53 -r1.54
--- vhost.c 2001/02/08 07:44:22 1.53
+++ vhost.c 2001/02/10 13:05:29 1.54
@@ -61,6 +61,13 @@
* (configuration and run-time)
*/
+#include "apr.h"
+#include "apr_strings.h"
+#include "apr_lib.h"
+
+#define APR_WANT_STRFUNC
+#include "apr_want.h"
+
#define CORE_PRIVATE
#include "ap_config.h"
#include "httpd.h"
@@ -69,23 +76,6 @@
#include "http_vhost.h"
#include "http_protocol.h"
#include "http_core.h"
-#include "apr_strings.h"
-
-#ifdef HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
-#ifdef HAVE_NETINET_IN_H
-#include <netinet/in.h>
-#endif
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-#ifdef HAVE_NETDB_H
-#include <netdb.h>
-#endif
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
/*
* After all the definitions there's an explanation of how it's all put