httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c...@hyperreal.org
Subject cvs commit: apachen/src/main alloc.h buff.h conf.h http_conf_globals.h http_config.h http_core.h http_log.h http_main.h http_protocol.h http_request.h http_vhost.h httpd.h md5.h multithread.h rfc1413.h scoreboard.h util_date.h util_md5.h util_script.h
Date Wed, 21 Jan 1998 18:24:03 GMT
coar        98/01/21 10:24:03

  Modified:    src      CHANGES
               src/ap   ap.h
               src/main alloc.h buff.h conf.h http_conf_globals.h
                        http_config.h http_core.h http_log.h http_main.h
                        http_protocol.h http_request.h http_vhost.h httpd.h
                        md5.h multithread.h rfc1413.h scoreboard.h
                        util_date.h util_md5.h util_script.h
  Log:
  	Add #ifndef wrappers to src/main/*.h files to insulate them
  	against multiple inclusions.  httpd.h now includes ap.h for
  	the ap_*() routines.
  
  Reviewed by:	Commit-then-review rules
  
  Revision  Changes    Path
  1.572     +8 -0      apachen/src/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/CHANGES,v
  retrieving revision 1.571
  retrieving revision 1.572
  diff -u -r1.571 -r1.572
  --- CHANGES	1998/01/20 18:56:51	1.571
  +++ CHANGES	1998/01/21 18:23:42	1.572
  @@ -1,5 +1,13 @@
   Changes with Apache 1.3b4
   
  +  *) The src/main/*.h header files have had #ifndef wrappers added to
  +     insulate them against duplicate calls if they get included through
  +     multiple paths (e.g., in .c files as well as other .h files).
  +     [Ken Coar]
  +
  +  *) The libap routines now have a header file for their prototypes,
  +     src/ap/ap.h, to ease their use in non-httpd applications.  [Ken Coar]
  +
     *) mod_autoindex with a plaintext header file would emit the <PRE>
        start-tag before the HTML preamble, rather than after the preamble
        but before the header file contents.  [John Van Essen <jve@gamers.org>]
  
  
  
  1.2       +3 -3      apachen/src/ap/ap.h
  
  Index: ap.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/ap/ap.h,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ap.h	1998/01/21 17:12:40	1.1
  +++ ap.h	1998/01/21 18:23:46	1.2
  @@ -54,8 +54,8 @@
    * <panos@alumni.cs.colorado.edu> for xinetd.
    */
   
  -#ifndef _AP_H
  -#define _AP_H
  +#ifndef _APACHE_AP_H
  +#define _APACHE_AP_H
   
   API_EXPORT(char *) ap_cpystrn(char *, const char *, size_t);
   int ap_slack(int, int);
  @@ -63,4 +63,4 @@
   API_EXPORT(int) ap_snprintf(char *, size_t, const char *, ...);
   API_EXPORT(int) ap_vsnprintf(char *, size_t, const char *, va_list ap);
   
  -#endif
  +#endif	/* !_APACHE_AP_H */
  
  
  
  1.39      +5 -0      apachen/src/main/alloc.h
  
  Index: alloc.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/alloc.h,v
  retrieving revision 1.38
  retrieving revision 1.39
  diff -u -r1.38 -r1.39
  --- alloc.h	1998/01/07 16:45:59	1.38
  +++ alloc.h	1998/01/21 18:23:47	1.39
  @@ -52,6 +52,9 @@
    *
    */
   
  +#ifndef _APACHE_ALLOC_H
  +#define _APACHE_ALLOC_H
  +
   /*
    * Resource allocation routines...
    *
  @@ -276,3 +279,5 @@
   
   API_EXPORT(long) bytes_in_pool(pool *p);
   API_EXPORT(long) bytes_in_free_blocks(void);
  +
  +#endif	/* !_APACHE_ALLOC_H */
  
  
  
  1.31      +5 -0      apachen/src/main/buff.h
  
  Index: buff.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/buff.h,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -r1.30 -r1.31
  --- buff.h	1998/01/16 14:22:54	1.30
  +++ buff.h	1998/01/21 18:23:47	1.31
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_BUFF_H
  +#define _APACHE_BUFF_H
  +
   #ifdef B_SFIO
   #include "sfio.h"
   #endif
  @@ -189,3 +192,5 @@
   
   /* bflush() if a read now would block, but don't actually read anything */
   API_EXPORT(void) bhalfduplex(BUFF *fb);
  +
  +#endif	/* !_APACHE_BUFF_H */
  
  
  
  1.167     +5 -0      apachen/src/main/conf.h
  
  Index: conf.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/conf.h,v
  retrieving revision 1.166
  retrieving revision 1.167
  diff -u -r1.166 -r1.167
  --- conf.h	1998/01/13 23:11:08	1.166
  +++ conf.h	1998/01/21 18:23:48	1.167
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_CONF_H
  +#define _APACHE_CONF_H
  +
   /*
    * conf.h: system-dependant #defines and includes...
    * See README for a listing of what they mean
  @@ -1047,3 +1050,5 @@
   #ifdef NEED_DIFFTIME
   extern double difftime(time_t time1, time_t time0);
   #endif
  +
  +#endif	/* !_APACHE_CONF_H */
  
  
  
  1.23      +5 -0      apachen/src/main/http_conf_globals.h
  
  Index: http_conf_globals.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/http_conf_globals.h,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- http_conf_globals.h	1998/01/11 20:25:01	1.22
  +++ http_conf_globals.h	1998/01/21 18:23:48	1.23
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_HTTP_CONF_GLOBALS_H
  +#define _APACHE_HTTP_CONF_GLOBALS_H
  +
   /* 
    * Process config --- what the process ITSELF is doing
    */
  @@ -96,3 +99,5 @@
    * is some memory corruption, so we allocate it statically.
    */
   extern char coredump_dir[MAX_STRING_LEN];
  +
  +#endif	/* !_APACHE_HTTP_CONF_GLOBALS_H */
  
  
  
  1.60      +5 -0      apachen/src/main/http_config.h
  
  Index: http_config.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/http_config.h,v
  retrieving revision 1.59
  retrieving revision 1.60
  diff -u -r1.59 -r1.60
  --- http_config.h	1998/01/07 16:46:03	1.59
  +++ http_config.h	1998/01/21 18:23:49	1.60
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_HTTP_CONFIG_H
  +#define _APACHE_HTTP_CONFIG_H
  +
   /*
    * The central data structures around here...
    */
  @@ -330,3 +333,5 @@
   int run_post_read_request(request_rec *);
   
   #endif
  +
  +#endif	/* !_APACHE_HTTP_CONFIG_H */
  
  
  
  1.31      +5 -0      apachen/src/main/http_core.h
  
  Index: http_core.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/http_core.h,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -r1.30 -r1.31
  --- http_core.h	1998/01/07 16:46:04	1.30
  +++ http_core.h	1998/01/21 18:23:50	1.31
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_HTTP_CORE_H
  +#define _APACHE_HTTP_CORE_H
  +
   /*****************************************************************
    *
    * The most basic server code is encapsulated in a single module
  @@ -217,3 +220,5 @@
   } core_server_config;
   
   #endif
  +
  +#endif	/* !_APACHE_HTTP_CORE_H */
  
  
  
  1.24      +5 -0      apachen/src/main/http_log.h
  
  Index: http_log.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/http_log.h,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -r1.23 -r1.24
  --- http_log.h	1998/01/07 16:46:05	1.23
  +++ http_log.h	1998/01/21 18:23:51	1.24
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_HTTP_LOG_H
  +#define _APACHE_HTTP_LOG_H
  +
   #ifdef HAVE_SYSLOG
   #include <syslog.h>
   
  @@ -128,3 +131,5 @@
   #define piped_log_read_fd(pl)	(-1)
   #define piped_log_write_fd(pl)	(fileno((pl)->write_f))
   #endif
  +
  +#endif	/* !_APACHE_HTTP_LOG_H */
  
  
  
  1.23      +5 -0      apachen/src/main/http_main.h
  
  Index: http_main.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/http_main.h,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- http_main.h	1998/01/07 16:46:07	1.22
  +++ http_main.h	1998/01/21 18:23:51	1.23
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_HTTP_MAIN_H
  +#define _APACHE_HTTP_MAIN_H
  +
   /*
    * Routines in http_main.c which other code --- in particular modules ---
    * may want to call.  Right now, that's limited to timeout handling.
  @@ -140,3 +143,5 @@
   API_EXPORT(void) unregister_other_child(void *data);
   
   #endif
  +
  +#endif	/* !_APACHE_HTTP_MAIN_H */
  
  
  
  1.33      +5 -0      apachen/src/main/http_protocol.h
  
  Index: http_protocol.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/http_protocol.h,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -r1.32 -r1.33
  --- http_protocol.h	1998/01/07 16:46:11	1.32
  +++ http_protocol.h	1998/01/21 18:23:52	1.33
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_HTTP_PROTOCOL_H
  +#define _APACHE_HTTP_PROTOCOL_H
  +
   /*
    * Prototypes for routines which either talk directly back to the user,
    * or control the ones that eventually do.
  @@ -200,3 +203,5 @@
   /* This is also useful for putting sub_reqs and internal_redirects together */
   
   void parse_uri(request_rec *r, const char *uri);
  +
  +#endif	/* !_APACHE_HTTP_PROTOCOL_H */
  
  
  
  1.19      +5 -0      apachen/src/main/http_request.h
  
  Index: http_request.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/http_request.h,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- http_request.h	1998/01/07 16:46:16	1.18
  +++ http_request.h	1998/01/21 18:23:52	1.19
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_HTTP_REQUEST_H
  +#define _APACHE_HTTP_REQUEST_H
  +
   /* http_request.c is the code which handles the main line of request
    * processing, once a request has been read in (finding the right per-
    * directory configuration, building it if necessary, and calling all
  @@ -96,3 +99,5 @@
   int default_handler(request_rec *);
   void die(int type, request_rec *r);
   #endif
  +
  +#endif	/* !_APACHE_HTTP_REQUEST_H */
  
  
  
  1.4       +3 -3      apachen/src/main/http_vhost.h
  
  Index: http_vhost.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/http_vhost.h,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- http_vhost.h	1998/01/07 16:46:17	1.3
  +++ http_vhost.h	1998/01/21 18:23:53	1.4
  @@ -51,8 +51,8 @@
    *
    */
   
  -#ifndef HTTP_VHOST_H
  -#define HTTP_VHOST_H
  +#ifndef _APACHE_HTTP_VHOST_H
  +#define _APACHE_HTTP_VHOST_H
   
   /* called before any config is read */
   void init_vhost_config(pool *p);
  @@ -74,4 +74,4 @@
    */
   void update_vhost_from_headers(request_rec *r);
   
  -#endif
  +#endif	/* !_APACHE_HTTP_VHOST_H */
  
  
  
  1.173     +5 -3      apachen/src/main/httpd.h
  
  Index: httpd.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/httpd.h,v
  retrieving revision 1.172
  retrieving revision 1.173
  diff -u -r1.172 -r1.173
  --- httpd.h	1998/01/13 23:11:13	1.172
  +++ httpd.h	1998/01/21 18:23:53	1.173
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_HTTPD_H
  +#define _APACHE_HTTPD_H
  +
   /*
    * httpd.h: header for simple (ha! not anymore) http daemon
    */
  @@ -60,6 +63,7 @@
   #include "conf.h"
   #include "alloc.h"
   #include "buff.h"
  +#include "ap.h"
   
   /* ----------------------------- config dir ------------------------------ */
   
  @@ -942,6 +946,4 @@
   #define RAISE_SIGSTOP(x)
   #endif
   
  -/* Our own home-brewed strncpy replacement */
  -API_EXPORT(char *) ap_cpystrn(char *dst, const char *src, size_t dst_size);
  -
  +#endif	/* !_APACHE_HTTPD_H */
  
  
  
  1.10      +4 -0      apachen/src/main/md5.h
  
  Index: md5.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/md5.h,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- md5.h	1998/01/07 16:46:19	1.9
  +++ md5.h	1998/01/21 18:23:54	1.10
  @@ -81,6 +81,8 @@
    *
    */
   
  +#ifndef _APACHE_MD5_H
  +#define _APACHE_MD5_H
   
   /* MD5.H - header file for MD5C.C */
   
  @@ -98,3 +100,5 @@
   API_EXPORT(void) MD5Update(AP_MD5_CTX * context, const unsigned char *input,
   			   unsigned int inputLen);
   API_EXPORT(void) MD5Final(unsigned char digest[16], AP_MD5_CTX * context);
  +
  +#endif	/* !_APACHE_MD5_H */
  
  
  
  1.8       +3 -3      apachen/src/main/multithread.h
  
  Index: multithread.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/multithread.h,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- multithread.h	1997/12/26 23:22:10	1.7
  +++ multithread.h	1998/01/21 18:23:54	1.8
  @@ -1,5 +1,5 @@
  -#ifndef MULTITHREAD_H
  -#define MULTITHREAD_H
  +#ifndef _APACHE_MULTITHREAD_H
  +#define _APACHE_MULTITHREAD_H
   
   #define MULTI_OK (0)
   #define MULTI_TIMEOUT (1)
  @@ -54,4 +54,4 @@
   
   #endif /* ndef MULTITHREAD */
   
  -#endif /* ndef MULTITHREAD_H */
  +#endif /* !_APACHE_MULTITHREAD_H */
  
  
  
  1.7       +5 -0      apachen/src/main/rfc1413.h
  
  Index: rfc1413.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/rfc1413.h,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- rfc1413.h	1998/01/07 16:46:20	1.6
  +++ rfc1413.h	1998/01/21 18:23:55	1.7
  @@ -51,4 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_RFC1413_H
  +#define _APACHE_RFC1413_H
  +
   extern char *rfc1413(conn_rec *conn, server_rec *srv);
  +
  +#endif	/* !_APACHE_RFC1413_H */
  
  
  
  1.35      +5 -0      apachen/src/main/scoreboard.h
  
  Index: scoreboard.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/scoreboard.h,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -r1.34 -r1.35
  --- scoreboard.h	1998/01/07 16:46:21	1.34
  +++ scoreboard.h	1998/01/21 18:23:55	1.35
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_SCOREBOARD_H
  +#define _APACHE_SCOREBOARD_H
  +
   #ifndef WIN32
   #include <sys/times.h>
   #endif
  @@ -155,3 +158,5 @@
   /* for time_process_request() in http_main.c */
   #define START_PREQUEST 1
   #define STOP_PREQUEST  2
  +
  +#endif	/* !_APACHE_SCOREBOARD_H */
  
  
  
  1.8       +5 -0      apachen/src/main/util_date.h
  
  Index: util_date.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/util_date.h,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- util_date.h	1998/01/07 16:46:22	1.7
  +++ util_date.h	1998/01/21 18:23:56	1.8
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_UTIL_DATE_H
  +#define _APAcHE_UTIL_DATE_H
  +
   /*
    * util_date.h: prototypes for date parsing utility routines
    */
  @@ -66,3 +69,5 @@
   API_EXPORT(int) checkmask(const char *data, const char *mask);
   time_t tm2sec(const struct tm *t);
   API_EXPORT(time_t) parseHTTPdate(const char *date);
  +
  +#endif	/* !_APACHE_UTIL_DATE_H */
  
  
  
  1.11      +5 -0      apachen/src/main/util_md5.h
  
  Index: util_md5.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/util_md5.h,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- util_md5.h	1998/01/07 16:46:23	1.10
  +++ util_md5.h	1998/01/21 18:23:56	1.11
  @@ -51,8 +51,13 @@
    *
    */
   
  +#ifndef _APACHE_UTIL_MD5_H
  +#define _APACHE_UTIL_MD5_H
  +
   #include "md5.h"
   
   API_EXPORT(char *) ap_md5(pool *a, unsigned char *string);
   API_EXPORT(char *) ap_md5contextTo64(pool *p, AP_MD5_CTX * context);
   API_EXPORT(char *) ap_md5digest(pool *p, FILE *infile);
  +
  +#endif	/* !_APACHE_UTIL_MD5_H */
  
  
  
  1.26      +9 -2      apachen/src/main/util_script.h
  
  Index: util_script.h
  ===================================================================
  RCS file: /export/home/cvs/apachen/src/main/util_script.h,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- util_script.h	1998/01/07 16:46:24	1.25
  +++ util_script.h	1998/01/21 18:23:57	1.26
  @@ -51,6 +51,9 @@
    *
    */
   
  +#ifndef _APACHE_UTIL_SCRIPT_H
  +#define _APACHE_UTIL_SCRIPT_H
  +
   #ifndef APACHE_ARG_MAX
   #ifdef _POSIX_ARG_MAX
   #define APACHE_ARG_MAX _POSIX_ARG_MAX
  @@ -65,6 +68,10 @@
   API_EXPORT(void) add_common_vars(request_rec *r);
   #define scan_script_header(a1,a2) scan_script_header_err(a1,a2,NULL)
   API_EXPORT(int) scan_script_header_err(request_rec *r, FILE *f, char *buffer);
  -API_EXPORT(int) scan_script_header_err_buff(request_rec *r, BUFF *f, char *buffer);
  +API_EXPORT(int) scan_script_header_err_buff(request_rec *r, BUFF *f,
  +                                            char *buffer);
   API_EXPORT(void) send_size(size_t size, request_rec *r);
  -API_EXPORT(int) call_exec(request_rec *r, char *argv0, char **env, int shellcmd);
  +API_EXPORT(int) call_exec(request_rec *r, char *argv0, char **env,
  +                          int shellcmd);
  +
  +#endif	/* !_APACHE_UTIL_SCRIPT_H */
  
  
  

Mime
View raw message