cvs commit: apache-2.0/src/lib/apr/lib apr_snprintf.c
jim 99/12/13 05:36:17 Modified:src/lib/apr/lib apr_snprintf.c Log: Fold in the snprintf() changes Revision ChangesPath 1.5 +202 -44 apache-2.0/src/lib/apr/lib/apr_snprintf.c Index: apr_snprintf.c === RCS file: /export/home/cvs/apache-2.0/src/lib/apr/lib/apr_snprintf.c,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- apr_snprintf.c1999/12/09 21:00:44 1.4 +++ apr_snprintf.c1999/12/13 13:36:16 1.5 @@ -54,7 +54,7 @@ * project, please see http://www.apache.org/. * * This code is based on, and used with the permission of, the - * SIO stdiocntxteplacement strx_* functions by Panos Tsirigotis + * SIO stdio-replacement strx_* functions by Panos Tsirigotis * [EMAIL PROTECTED] for xinetd. */ @@ -90,12 +90,22 @@ #ifndef TRUE #define TRUE 1 #endif +#ifndef AP_LONGEST_LONG +#define AP_LONGEST_LONG long +#endif #define NUL '\0' -#define INT_NULL ((int *)0) #define WIDE_INT long +#define WIDEST_INT AP_LONGEST_LONG typedef WIDE_INT wide_int; typedef unsigned WIDE_INT u_wide_int; +typedef WIDEST_INT widest_int; +#ifdef __TANDEM +/* Although Tandem supports long long there is no unsigned variant. */ +typedef unsigned long u_widest_int; +#else +typedef unsigned WIDEST_INT u_widest_int; +#endif typedef int bool_int; #define S_NULL (null) @@ -131,7 +141,7 @@ register int r2; double fi, fj; register char *p, *p1; - + if (ndigits = NDIG - 1) ndigits = NDIG - 2; r2 = 0; @@ -350,6 +360,10 @@ * The caller provides a buffer for the string: that is the buf_end argument * which is a pointer to the END of the buffer + 1 (i.e. if the buffer * is declared as buf[ 100 ], buf_end should be buf[ 100 ]) + * + * Note: we have 2 versions. One is used when we need to use quads + * (conv_10_quad), the other when we don't (conv_10). We're assuming the + * latter is faster. */ static char *conv_10(register wide_int num, register bool_int is_unsigned, register bool_int *is_negative, char *buf_end, @@ -398,6 +412,62 @@ return (p); } +static char *conv_10_quad(widest_int num, register bool_int is_unsigned, + register bool_int *is_negative, char *buf_end, + register int *len) +{ +register char *p = buf_end; +u_widest_int magnitude; + +/* + * We see if we can use the faster non-quad version by checking the + * number against the largest long value it can be. If =, we + * punt to the quicker version. + */ +if ((num = ULONG_MAX is_unsigned) || (num = LONG_MAX !is_unsigned)) + return(conv_10( (wide_int)num, is_unsigned, is_negative, +buf_end, len)); + +if (is_unsigned) { + magnitude = (u_widest_int) num; + *is_negative = FALSE; +} +else { + *is_negative = (num 0); + + /* + * On a 2's complement machine, negating the most negative integer + * results in a number that cannot be represented as a signed integer. + * Here is what we do to obtain the number's magnitude: + * a. add 1 to the number + * b. negate it (becomes positive) + * c. convert it to unsigned + * d. add 1 + */ + if (*is_negative) { + widest_int t = num + 1; + + magnitude = ((u_widest_int) -t) + 1; + } + else + magnitude = (u_widest_int) num; +} + +/* + * We use a do-while loop so that we write at least 1 digit + */ +do { + u_widest_int new_magnitude = magnitude / 10; + + *--p = (char) (magnitude - new_magnitude * 10 + '0'); + magnitude = new_magnitude; +} +while (magnitude); + +*len = buf_end - p; +return (p); +} + static char *conv_in_addr(struct in_addr *ia, char *buf_end, int *len) @@ -537,6 +607,9 @@ * The caller provides a buffer for the string: that is the buf_end argument * which is a pointer to the END of the buffer + 1 (i.e. if the buffer * is declared as buf[ 100 ], buf_end should be buf[ 100 ]) + * + * As with conv_10, we have a faster version which is used when + * the number isn't quad size. */ static char *conv_p2(register u_wide_int num, register int nbits, char format, char *buf_end, register int *len) @@ -557,12 +630,34 @@ return (p); } +static char *conv_p2_quad(u_widest_int num, register int nbits, + char format, char *buf_end, register int *len) +{ +register int mask = (1 nbits) - 1; +register char *p = buf_end; +static
cvs commit: apache-2.0/src/lib/apr/lib apr_snprintf.c
jim 99/12/13 05:39:24 Modified:src/lib/apr/lib apr_snprintf.c Log: Use the ap_vformatter_buff_t type :) Revision ChangesPath 1.6 +5 -5 apache-2.0/src/lib/apr/lib/apr_snprintf.c Index: apr_snprintf.c === RCS file: /export/home/cvs/apache-2.0/src/lib/apr/lib/apr_snprintf.c,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- apr_snprintf.c1999/12/13 13:36:16 1.5 +++ apr_snprintf.c1999/12/13 13:39:23 1.6 @@ -656,8 +656,8 @@ /* * Do format conversion placing the output in buffer */ -API_EXPORT(int) ap_vformatter(int (*flush_func)(ap_vformatter_buff *), -ap_vformatter_buff *vbuff, const char *fmt, va_list ap) +API_EXPORT(int) ap_vformatter(int (*flush_func)(ap_vformatter_buff_t *), +ap_vformatter_buff_t *vbuff, const char *fmt, va_list ap) { register char *sp; register char *bep; @@ -1149,7 +1149,7 @@ } -static int snprintf_flush(ap_vformatter_buff *vbuff) +static int snprintf_flush(ap_vformatter_buff_t *vbuff) { /* if the buffer fills we have to abort immediately, there is no way * to flush an ap_snprintf... there's nowhere to flush it to. @@ -1162,7 +1162,7 @@ { int cc; va_list ap; -ap_vformatter_buff vbuff; +ap_vformatter_buff_t vbuff; if (len == 0) return 0; @@ -1182,7 +1182,7 @@ va_list ap) { int cc; -ap_vformatter_buff vbuff; +ap_vformatter_buff_t vbuff; if (len == 0) return 0;
cvs commit: apache-1.3 STATUS
martin 99/12/13 05:52:54 Modified:.STATUS Log: Update IPv6 Patch Revision ChangesPath 1.767 +5 -4 apache-1.3/STATUS Index: STATUS === RCS file: /export/home/cvs/apache-1.3/STATUS,v retrieving revision 1.766 retrieving revision 1.767 diff -u -r1.766 -r1.767 --- STATUS1999/12/10 12:22:41 1.766 +++ STATUS1999/12/13 13:52:53 1.767 @@ -1,5 +1,5 @@ 1.3 STATUS: - Last modified at [$Date: 1999/12/10 12:22:41 $] + Last modified at [$Date: 1999/12/13 13:52:53 $] Release: @@ -136,10 +136,11 @@ Status: Bill +1 (on concept), Lars +1 (on concept) * Jun-ichiro itojun Hagino's [PATCH] IPv6 enable patch - ftp://ftp.kame.net/pub/kame/misc/apache-134-v6-19990118.diff.gz -Message-ID: [EMAIL PROTECTED] + ftp://ftp.kame.net/pub/kame/misc/apache-139-v6-19991013a.diff.gz + Message-ID: [EMAIL PROTECTED], + [EMAIL PROTECTED] Status: Lars +1 (on concept), Dirkx +1 (tested), - Martin +1 (on concept; the patch may need a little cleanup) + Martin +1 (on concept) * Jim Patterson's patch to make mod_info work on Win32 Message-ID: PR#1442
cvs commit: apache-2.0/src/lib/apr/file_io/unix filedup.c open.c
rbb 99/12/13 05:57:10 Modified:src/lib/apr/file_io/unix filedup.c open.c Log: A bug fix to ap_open_stderr, and a new feature for ap_dupfile. The previous implementation wouldn't let the user supply two file descriptors and make them equivalent, it would only allow us to create a new descriptor. This wasn't good enough. This patch rectifies that problem. Revision ChangesPath 1.7 +16 -5 apache-2.0/src/lib/apr/file_io/unix/filedup.c Index: filedup.c === RCS file: /home/cvs/apache-2.0/src/lib/apr/file_io/unix/filedup.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- filedup.c 1999/12/03 15:18:22 1.6 +++ filedup.c 1999/12/13 13:57:05 1.7 @@ -64,12 +64,18 @@ ap_status_t ap_dupfile(struct file_t **new_file, struct file_t *old_file) { char *buf_oflags; -(*new_file) = (struct file_t *)ap_palloc(old_file-cntxt, - sizeof(struct file_t)); - +int have_file = 0; + if ((*new_file) == NULL) { -return APR_ENOMEM; +(*new_file) = (struct file_t *)ap_pcalloc(old_file-cntxt, + sizeof(struct file_t)); +if ((*new_file) == NULL) { +return APR_ENOMEM; +} +} else { +have_file = 1; } + (*new_file)-cntxt = old_file-cntxt; if (old_file-buffered) { switch (old_file-oflags) { @@ -89,7 +95,12 @@ old_file-filehand); } else { -(*new_file)-filedes = dup(old_file-filedes); +if (have_file) { +dup2(old_file-filedes, (*new_file)-filedes); +} +else { +(*new_file)-filedes = dup(old_file-filedes); +} } (*new_file)-fname = ap_pstrdup(old_file-cntxt, old_file-fname); (*new_file)-buffered = old_file-buffered; 1.27 +2 -1 apache-2.0/src/lib/apr/file_io/unix/open.c Index: open.c === RCS file: /home/cvs/apache-2.0/src/lib/apr/file_io/unix/open.c,v retrieving revision 1.26 retrieving revision 1.27 diff -u -r1.26 -r1.27 --- open.c1999/12/11 20:24:13 1.26 +++ open.c1999/12/13 13:57:06 1.27 @@ -307,12 +307,13 @@ */ ap_status_t ap_open_stderr(struct file_t **thefile, ap_context_t *cont) { -(*thefile) = ap_palloc(cont, sizeof(ap_os_file_t *)); +(*thefile) = ap_pcalloc(cont, sizeof(ap_os_file_t *)); if ((*thefile) == NULL) { return APR_ENOMEM; } (*thefile)-filedes = STDERR_FILENO; (*thefile)-cntxt = cont; +(*thefile)-fname = NULL; (*thefile)-filehand = NULL; (*thefile)-stated = 0; (*thefile)-buffered = 0;
cvs commit: apache-2.0/src/modules/mpm/mpmt_pthread mpmt_pthread.c
rbb 99/12/13 06:01:36 Modified:src/main http_log.c src/modules/mpm/mpmt_pthread mpmt_pthread.c Log: Get rid of a couple more ap_os_file_t's along with their platform dependant code. Revision ChangesPath 1.21 +9 -14 apache-2.0/src/main/http_log.c Index: http_log.c === RCS file: /home/cvs/apache-2.0/src/main/http_log.c,v retrieving revision 1.20 retrieving revision 1.21 diff -u -r1.20 -r1.21 --- http_log.c1999/12/02 18:36:31 1.20 +++ http_log.c1999/12/13 14:01:34 1.21 @@ -265,7 +265,7 @@ { server_rec *virt, *q; int replace_stderr; -ap_os_file_t errfile; +ap_file_t *errfile = NULL; open_error_log(s_main, p); @@ -273,8 +273,8 @@ if (s_main-error_log) { /* replace stderr with this new log */ fflush(stderr); -ap_get_os_file(errfile, s_main-error_log); - if (dup2(errfile, STDERR_FILENO) == -1) { +ap_open_stderr(errfile, p); + if (ap_dupfile(errfile, s_main-error_log) != APR_SUCCESS) { ap_log_error(APLOG_MARK, APLOG_CRIT, errno, s_main, unable to replace stderr with error_log); } else { @@ -307,12 +307,12 @@ } API_EXPORT(void) ap_error_log2stderr(server_rec *s) { -ap_os_file_t errfile; +ap_file_t *errfile; -ap_get_os_file(errfile, s-error_log); -if ( s-error_log != NULL - errfile != STDERR_FILENO) -dup2(errfile, STDERR_FILENO); +ap_open_stderr(errfile, s-process-pool); +if ( s-error_log != NULL) { +ap_dupfile((s-error_log), errfile); +} } static void log_error_core(const char *file, int line, int level, @@ -322,7 +322,6 @@ char errstr[MAX_STRING_LEN + 1];/* + 1 to have room for '\n' */ size_t len; ap_file_t *logf = NULL; -ap_os_file_t errfileno = STDERR_FILENO; if (s == NULL) { /* @@ -333,11 +332,7 @@ if (((level APLOG_LEVELMASK) != APLOG_NOTICE) ((level APLOG_LEVELMASK) DEFAULT_LOGLEVEL)) return; -#ifdef WIN32 -/* This is where the different ap_put_os_file's belong */ -#else - ap_put_os_file(logf, errfileno, NULL); -#endif + ap_open_stderr(logf, NULL); } else if (s-error_log) { /* 1.52 +0 -1 apache-2.0/src/modules/mpm/mpmt_pthread/mpmt_pthread.c Index: mpmt_pthread.c === RCS file: /home/cvs/apache-2.0/src/modules/mpm/mpmt_pthread/mpmt_pthread.c,v retrieving revision 1.51 retrieving revision 1.52 diff -u -r1.51 -r1.52 --- mpmt_pthread.c1999/12/03 22:11:22 1.51 +++ mpmt_pthread.c1999/12/13 14:01:35 1.52 @@ -1502,7 +1502,6 @@ if (!one_process) { unixd_detach(); } - my_pid = getpid(); }
cvs commit: apache-1.3/src/modules/standard mod_mime.c
martin 99/12/13 06:17:37 Modified:src/modules/standard mod_mime.c Log: Avoid *all* side effects of signed/unsigned char sign extensions. (Probably unneccessary, but this tests only the single bit 7) Revision ChangesPath 1.52 +1 -1 apache-1.3/src/modules/standard/mod_mime.c Index: mod_mime.c === RCS file: /export/home/cvs/apache-1.3/src/modules/standard/mod_mime.c,v retrieving revision 1.51 retrieving revision 1.52 diff -u -r1.51 -r1.52 --- mod_mime.c1999/12/10 14:51:03 1.51 +++ mod_mime.c1999/12/13 14:17:37 1.52 @@ -73,7 +73,7 @@ * defined it's not always right for our needs. Roll our own that * we can rely on. */ -#define ap_isascii(c) ((OS_ASC(c) ~0177) != 0) +#define ap_isascii(c) ((OS_ASC(c) 0x80) == 0) typedef struct handlers_info { char *name;
cvs commit: apache-1.3/src Configure
martin 99/12/13 06:33:27 Modified:src Configure Log: Undo recent shell-env-workaround for MPE/iX. Use explicit export to force variables into environment. Revision ChangesPath 1.380 +3 -3 apache-1.3/src/Configure Index: Configure === RCS file: /export/home/cvs/apache-1.3/src/Configure,v retrieving revision 1.379 retrieving revision 1.380 diff -u -r1.379 -r1.380 --- Configure 1999/12/10 11:03:07 1.379 +++ Configure 1999/12/13 14:33:26 1.380 @@ -907,9 +907,9 @@ ## TCPP=`egrep '^CPP=' Makefile.config | tail -1 | awk -F= '{print $2}'` if [ x$TCPP != x ]; then -CPP=`env CC=$CC CPP=$TCPP ./helpers/findcpp.sh` +CPP=`CPP=$TCPP; export CPP CC; ./helpers/findcpp.sh` else -CPP=`env CC=$CC ./helpers/findcpp.sh` +CPP=`export CC; ./helpers/findcpp.sh` fi if [ x$TCPP = x ]; then echo CPP=$CPP Makefile.config @@ -935,7 +935,7 @@ echo $AP_CONFIG_AUTO_H echo /* check: #include $header */ $AP_CONFIG_AUTO_H name=`echo $header | sed -e 's:/:_:g' -e 's:\.:_:g' | tr '[a-z]' '[A-Z]'` -env CPP=$CPP ./helpers/checkheader.sh $header +( export CPP; ./helpers/checkheader.sh $header ) if [ $? -eq 0 ]; then echo #ifndef HAVE_${name} $AP_CONFIG_AUTO_H echo #define HAVE_${name} 1 $AP_CONFIG_AUTO_H
cvs commit: apache-2.0 STATUS
stoddard99/12/13 07:46:45 Modified:.STATUS Log: Update STATUS Revision ChangesPath 1.22 +4 -3 apache-2.0/STATUS Index: STATUS === RCS file: /home/cvs/apache-2.0/STATUS,v retrieving revision 1.21 retrieving revision 1.22 diff -u -r1.21 -r1.22 --- STATUS1999/12/02 06:33:05 1.21 +++ STATUS1999/12/13 15:46:45 1.22 @@ -1,5 +1,5 @@ Apache 2.0 STATUS: -Last modified at [$Date: 1999/12/02 06:33:05 $] +Last modified at [$Date: 1999/12/13 15:46:45 $] Release: @@ -37,10 +37,11 @@ Remaining work: 1. Add back ability to run Apache as a service 2. Fix Win9* specific code in the winnt MPM -3. Get the MPM working in multi process mode (one parent one child) -4. Test access logging with multiple threads. Will the native file I/O +3. Test access logging with multiple threads. Will the native file I/O calls serialize automagically like the CRT calls or do we need to add region locking each time we write to the access/error logs? +4. Fix the DOS hole in AcceptEx (need to time out connections over + which data is never sent). * Current 2.0 code is not tested on many Unix platforms. Make 2.0 work on most, if not all the systems 1.3 did
cvs commit: apache-1.3 STATUS
martin 99/12/13 08:44:43 Modified:.STATUS Log: I'm all for including IPv6 support, but it musn't break any of the previously supported platforms. Revision ChangesPath 1.768 +4 -2 apache-1.3/STATUS Index: STATUS === RCS file: /export/home/cvs/apache-1.3/STATUS,v retrieving revision 1.767 retrieving revision 1.768 diff -u -r1.767 -r1.768 --- STATUS1999/12/13 13:52:53 1.767 +++ STATUS1999/12/13 16:44:42 1.768 @@ -1,5 +1,5 @@ 1.3 STATUS: - Last modified at [$Date: 1999/12/13 13:52:53 $] + Last modified at [$Date: 1999/12/13 16:44:42 $] Release: @@ -140,7 +140,9 @@ Message-ID: [EMAIL PROTECTED], [EMAIL PROTECTED] Status: Lars +1 (on concept), Dirkx +1 (tested), - Martin +1 (on concept) + Martin +1 (on concept, but patched apache does not + compile successfully on pre-IPv6-SVR4, + and possibly others) * Jim Patterson's patch to make mod_info work on Win32 Message-ID: PR#1442
cvs commit: apache-2.0/src/lib/apr/lib apr_pools.c
rbb 99/12/13 12:42:22 Modified:src/lib/apr/include apr_lib.h apr_pools.h src/lib/apr/lib apr_pools.c Log: Fi ap_note_subprocess to use ap_proc_t's instead of pid's. Revision ChangesPath 1.21 +2 -1 apache-2.0/src/lib/apr/include/apr_lib.h Index: apr_lib.h === RCS file: /home/cvs/apache-2.0/src/lib/apr/include/apr_lib.h,v retrieving revision 1.20 retrieving revision 1.21 diff -u -r1.20 -r1.21 --- apr_lib.h 1999/12/01 20:35:34 1.20 +++ apr_lib.h 1999/12/13 20:42:02 1.21 @@ -66,6 +66,7 @@ #include apr_general.h #include apr_file_io.h +#include apr_thread_proc.h #if APR_HAVE_STDARG_H #include stdarg.h @@ -353,7 +354,7 @@ API_EXPORT(ap_status_t) ap_getpass(const char *prompt, char *pwbuf, size_t *bufsize); API_EXPORT_NONSTD(ap_status_t) ap_null_cleanup(void *data); -API_EXPORT(void) ap_note_subprocess(struct context_t *a, pid_t pid, +API_EXPORT(void) ap_note_subprocess(struct context_t *a, ap_proc_t *pid, enum kill_conditions how); API_EXPORT(int) ap_spawn_child(ap_context_t *p, 1.8 +1 -14 apache-2.0/src/lib/apr/include/apr_pools.h Index: apr_pools.h === RCS file: /home/cvs/apache-2.0/src/lib/apr/include/apr_pools.h,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- apr_pools.h 1999/12/01 20:35:39 1.7 +++ apr_pools.h 1999/12/13 20:42:05 1.8 @@ -90,7 +90,7 @@ #endif struct process_chain { -pid_t pid; +ap_proc_t *pid; enum kill_conditions kill_how; struct process_chain *next; }; @@ -241,19 +241,6 @@ */ #define ap_table_elts(t) ((ap_array_header_t *)(t)) #define ap_is_empty_table(t) (((t) == NULL)||(((ap_array_header_t *)(t))-nelts == 0)) - -/* ... even child processes (which we may want to wait for, - * or to kill outright, on unexpected termination). - * - * ap_spawn_child is a utility routine which handles an awful lot of - * the rigamarole associated with spawning a child --- it arranges - * for pipes to the child's stdin and stdout, if desired (if not, - * set the associated args to NULL). It takes as args a function - * to call in the child, and an argument to be passed to the function. - */ - -API_EXPORT(void) ap_note_subprocess(struct context_t *a, pid_t pid, - enum kill_conditions how); /* magic numbers --- min free bytes to consider a free ap_context_t block useable, * and the min amount to allocate if we have to go to malloc() */ 1.29 +6 -6 apache-2.0/src/lib/apr/lib/apr_pools.c Index: apr_pools.c === RCS file: /home/cvs/apache-2.0/src/lib/apr/lib/apr_pools.c,v retrieving revision 1.28 retrieving revision 1.29 diff -u -r1.28 -r1.29 --- apr_pools.c 1999/12/09 21:00:43 1.28 +++ apr_pools.c 1999/12/13 20:42:18 1.29 @@ -1216,7 +1216,7 @@ * generic interface, but for now, it's a special case */ -API_EXPORT(void) ap_note_subprocess(struct context_t *a, pid_t pid, +API_EXPORT(void) ap_note_subprocess(struct context_t *a, ap_proc_t *pid, enum kill_conditions how) { struct process_chain *new = @@ -1304,7 +1304,7 @@ #ifndef NEED_WAITPID /* Pick up all defunct processes */ for (p = procs; p; p = p-next) { - if (waitpid(p-pid, (int *) 0, WNOHANG) 0) { + if (ap_wait_proc(p-pid, APR_NOWAIT) 0) { p-kill_how = kill_never; } } @@ -1316,12 +1316,12 @@ /* * Subprocess may be dead already. Only need the timeout if not. */ - if (kill(p-pid, SIGTERM) != -1) { + if (ap_kill(p-pid, SIGTERM) != -1) { need_timeout = 1; } } else if (p-kill_how == kill_always) { - kill(p-pid, SIGKILL); + ap_kill(p-pid, SIGKILL); } } @@ -1339,11 +1339,11 @@ for (p = procs; p; p = p-next) { if (p-kill_how == kill_after_timeout) { - kill(p-pid, SIGKILL); + ap_kill(p-pid, SIGKILL); } if (p-kill_how != kill_never) { - waitpid(p-pid, status, 0); + status = ap_wait_proc(p-pid, APR_WAIT); } } #endif /* WIN32 */
cvs commit: apache-2.0/src/modules/standard mod_cgi.c mod_include.c mod_mime_magic.c
rbb 99/12/13 12:52:30 Modified:src/main http_log.c src/modules/standard mod_cgi.c mod_include.c mod_mime_magic.c Log: Get rid of more platform dependant code. Revision ChangesPath 1.22 +1 -9 apache-2.0/src/main/http_log.c Index: http_log.c === RCS file: /home/cvs/apache-2.0/src/main/http_log.c,v retrieving revision 1.21 retrieving revision 1.22 diff -u -r1.21 -r1.22 --- http_log.c1999/12/13 14:01:34 1.21 +++ http_log.c1999/12/13 20:52:26 1.22 @@ -166,7 +166,6 @@ int rc = -1; ap_procattr_t *procattr; ap_proc_t *procnew; -ap_os_proc_t fred; ap_block_alarms(); ap_cleanup_for_exec(); @@ -189,14 +188,7 @@ rc = ap_create_process(procnew, progname, NULL, NULL, procattr, p); if (rc == APR_SUCCESS) { -#ifndef WIN32 -/* pjr - this is a cheap hack for now to get the basics working in - * stages. ap_note_subprocess and free_proc need to be redone - * to make use of ap_proc_t instead of pid. - */ -ap_get_os_proc(fred, procnew); -ap_note_subprocess(p, fred, kill_after_timeout); -#endif +ap_note_subprocess(p, procnew, kill_after_timeout); ap_get_childin(fpin, procnew); } } 1.20 +2 -9 apache-2.0/src/modules/standard/mod_cgi.c Index: mod_cgi.c === RCS file: /home/cvs/apache-2.0/src/modules/standard/mod_cgi.c,v retrieving revision 1.19 retrieving revision 1.20 diff -u -r1.19 -r1.20 --- mod_cgi.c 1999/12/02 18:36:36 1.19 +++ mod_cgi.c 1999/12/13 20:52:28 1.20 @@ -284,7 +284,6 @@ char **env; ap_procattr_t *procattr; ap_proc_t *procnew; -ap_os_proc_t fred; ap_status_t rc = APR_SUCCESS; ap_file_t *file; ap_iol *iol; @@ -340,14 +339,8 @@ couldn't create child process: %d: %s, rc, r-filename); } else { -#ifndef WIN32 -/* pjr - this is a cheap hack for now to get the basics working in - * stages. ap_note_subprocess and free_proc need to be redone - * to make use of ap_proc_t instead of pid. - */ -ap_get_os_proc(fred, procnew); -ap_note_subprocess(p, fred, kill_after_timeout); -#endif +ap_note_subprocess(p, procnew, kill_after_timeout); + /* Fill in BUFF structure for parents pipe to child's stdout */ ap_get_childout(file, procnew); iol = ap_create_file_iol(file); 1.10 +1 -9 apache-2.0/src/modules/standard/mod_include.c Index: mod_include.c === RCS file: /home/cvs/apache-2.0/src/modules/standard/mod_include.c,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- mod_include.c 1999/12/02 18:36:37 1.9 +++ mod_include.c 1999/12/13 20:52:28 1.10 @@ -816,7 +816,6 @@ ap_status_t rc; ap_table_t *env = r-subprocess_env; char **argv; -ap_os_proc_t pid; ap_file_t *file; ap_iol *iol; @@ -870,14 +869,7 @@ couldn't create child process: %d: %s, rc, r-filename); } else { -#ifndef WIN32 -/* pjr - this is a cheap hack for now to get the basics working in - * stages. ap_note_subprocess and free_proc need to be redone - * to make use of ap_proc_t instead of pid. - */ -ap_get_os_proc(pid, procnew); -ap_note_subprocess(r-pool, pid, kill_after_timeout); -#endif +ap_note_subprocess(r-pool, procnew, kill_after_timeout); /* Fill in BUFF structure for parents pipe to child's stdout */ ap_get_childout(file, procnew); iol = ap_create_file_iol(file); 1.10 +1 -10 apache-2.0/src/modules/standard/mod_mime_magic.c Index: mod_mime_magic.c === RCS file: /home/cvs/apache-2.0/src/modules/standard/mod_mime_magic.c,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- mod_mime_magic.c 1999/12/02 18:36:39 1.9 +++ mod_mime_magic.c 1999/12/13 20:52:28 1.10 @@ -2153,7 +2153,6 @@ ap_context_t *child_context = cntxt; ap_procattr_t *procattr; ap_proc_t *procnew = NULL; -ap_os_proc_t fred; ap_file_t *file; ap_iol *iol; @@ -2190,15 +2189,7 @@ compr[parm-method].argv[0]); }
cvs commit: apache-1.3/src Configure
martin 99/12/13 14:00:19 Modified:src Configure Log: Oops. Add missing quotes. Noticed by Mark Bixby. Submitted by: Mark Bixby Revision ChangesPath 1.381 +1 -1 apache-1.3/src/Configure Index: Configure === RCS file: /export/home/cvs/apache-1.3/src/Configure,v retrieving revision 1.380 retrieving revision 1.381 diff -u -r1.380 -r1.381 --- Configure 1999/12/13 14:33:26 1.380 +++ Configure 1999/12/13 22:00:17 1.381 @@ -907,7 +907,7 @@ ## TCPP=`egrep '^CPP=' Makefile.config | tail -1 | awk -F= '{print $2}'` if [ x$TCPP != x ]; then -CPP=`CPP=$TCPP; export CPP CC; ./helpers/findcpp.sh` +CPP=`CPP=$TCPP; export CPP CC; ./helpers/findcpp.sh` else CPP=`export CC; ./helpers/findcpp.sh` fi
cvs commit: apache-2.0/src/modules/mpm/winnt winnt.h
rbb 99/12/13 14:53:26 Modified:src/include ap_mpm.h src/modules/mpm/dexter dexter.c src/modules/mpm/mpmt_beos mpmt_beos.h src/modules/mpm/mpmt_pthread mpmt_pthread.c mpmt_pthread.h scoreboard.c src/modules/mpm/winnt winnt.h Log: Fix some warnings when configured with --enable-maintainer-mode. ap_start_(shutdown|restart) are no longer static in dexter, because we explicitly state we are creating them to be called from places other than the parent. This is the first in a series of patches to get the 2.0 code to compile cleanly again. Revision ChangesPath 1.7 +16 -0 apache-2.0/src/include/ap_mpm.h Index: ap_mpm.h === RCS file: /home/cvs/apache-2.0/src/include/ap_mpm.h,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- ap_mpm.h 1999/11/19 20:26:59 1.6 +++ ap_mpm.h 1999/12/13 22:53:07 1.7 @@ -112,6 +112,22 @@ used by the connection loop */ API_EXPORT(int) ap_graceful_stop_signalled(void); +/* + * ap_start_shutdown() and ap_start_restart() are functions to initiate + * shutdown or restart without relying on signals. + * + * These should only be called from the parent process itself, since the + * parent process will use the shutdown_pending and restart_pending variables + * to determine whether to shutdown or restart. The child process should + * call signal_parent() directly to tell the parent to die -- this will + * cause neither of those variable to be set, which the parent will + * assume means something serious is wrong (which it will be, for the + * child to force an exit) and so do an exit anyway. + */ + +void ap_start_shutdown(void); +void ap_start_restart(int graceful); + #ifdef HAS_OTHER_CHILD /* * register an other_child -- a child which the main loop keeps track of 1.62 +2 -2 apache-2.0/src/modules/mpm/dexter/dexter.c Index: dexter.c === RCS file: /home/cvs/apache-2.0/src/modules/mpm/dexter/dexter.c,v retrieving revision 1.61 retrieving revision 1.62 diff -u -r1.61 -r1.62 --- dexter.c 1999/12/03 22:11:18 1.61 +++ dexter.c 1999/12/13 22:53:11 1.62 @@ -494,7 +494,7 @@ * child to force an exit) and so do an exit anyway. */ -static void ap_start_shutdown(void) +void ap_start_shutdown(void) { if (shutdown_pending == 1) { /* Um, is this _probably_ not an error, if the user has @@ -507,7 +507,7 @@ } /* do a graceful restart if graceful == 1 */ -static void ap_start_restart(int graceful) +void ap_start_restart(int graceful) { if (restart_pending == 1) { 1.3 +0 -1 apache-2.0/src/modules/mpm/mpmt_beos/mpmt_beos.h Index: mpmt_beos.h === RCS file: /home/cvs/apache-2.0/src/modules/mpm/mpmt_beos/mpmt_beos.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- mpmt_beos.h 1999/11/02 17:29:20 1.2 +++ mpmt_beos.h 1999/12/13 22:53:15 1.3 @@ -61,7 +61,6 @@ extern int ap_threads_per_child; extern int ap_max_requests_per_child; extern int ap_pipe_of_death[2]; -extern void clean_child_exit(int); extern int ap_extended_status; extern void clean_child_exit(int); extern int max_daemons_limit; 1.53 +2 -2 apache-2.0/src/modules/mpm/mpmt_pthread/mpmt_pthread.c Index: mpmt_pthread.c === RCS file: /home/cvs/apache-2.0/src/modules/mpm/mpmt_pthread/mpmt_pthread.c,v retrieving revision 1.52 retrieving revision 1.53 diff -u -r1.52 -r1.53 --- mpmt_pthread.c1999/12/13 14:01:35 1.52 +++ mpmt_pthread.c1999/12/13 22:53:19 1.53 @@ -181,8 +181,8 @@ return max_daemons_limit; } -/* a clean exit from a child with proper cleanup - static void clean_child_exit(int code) __attribute__ ((noreturn)); */ +/* a clean exit from a child with proper cleanup */ +static void clean_child_exit(int code) __attribute__ ((noreturn)); void clean_child_exit(int code) { if (pchild) { 1.4 +0 -1 apache-2.0/src/modules/mpm/mpmt_pthread/mpmt_pthread.h Index: mpmt_pthread.h === RCS file: /home/cvs/apache-2.0/src/modules/mpm/mpmt_pthread/mpmt_pthread.h,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- mpmt_pthread.h1999/07/16 05:30:29 1.3 +++ mpmt_pthread.h1999/12/13 22:53:20 1.4 @@ -61,7 +61,6 @@ extern int ap_threads_per_child; extern int ap_max_requests_per_child; extern int ap_pipe_of_death[2]; -extern void
cvs commit: apache-site/contributors index.html
jim 99/12/13 15:36:16 Modified:contributors index.html Log: Welcome to the 90s Revision ChangesPath 1.84 +2 -2 apache-site/contributors/index.html Index: index.html === RCS file: /export/home/cvs/apache-site/contributors/index.html,v retrieving revision 1.83 retrieving revision 1.84 diff -u -r1.83 -r1.84 --- index.html1999/12/06 17:05:47 1.83 +++ index.html1999/12/13 23:36:16 1.84 @@ -353,8 +353,8 @@ STRONGName:/STRONG A NAME=jagielskiJim Jagielski/ABR STRONGEmail:/STRONG A HREF=mailto:[EMAIL PROTECTED][EMAIL PROTECTED]/ABR -STRONGURL:/STRONG A HREF=http://www.jaguNET.com/;http://www.jaguNET.com//ABR -STRONGOrganization:/STRONG jaguNET Access Services, LLCBR +STRONGURL:/STRONG A HREF=http://www.jaguNET.com/jim.html;http://www.jaguNET.com/jim.html/ABR +STRONGOrganization:/STRONG A HREF=http://www.jaguNET.com/;jaguNET Access Services, LLC/ABR STRONGOccupation:/STRONG ISP and Web Hosting/Design firmBR STRONGLocation:/STRONG Forest Hill, Maryland, USABR STRONGOS Expertise:/STRONG A/UX and various SysV flavors, lately FreeBSDBR