apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r..@apache.org
Subject cvs commit: apr-util/buckets apr_buckets_heap.c
Date Tue, 06 Feb 2001 16:21:19 GMT
rbb         01/02/06 08:21:18

  Modified:    modules/generators mod_cgi.c mod_cgid.c
               buckets  apr_buckets_heap.c
  Log:
  Make sure that mod_include's post_config hook always runs before
  mod_cgi(d)'s post_config hook.  Mod_include creates a hash table in the
  post_config stage that mod_cgi(d) uses during it's post_config stage, so
  it must be done in this order.
  Submitted by:	 Brian Havard <brianh@kheldar.apana.org.au>
  
  Revision  Changes    Path
  1.84      +2 -1      httpd-2.0/modules/generators/mod_cgi.c
  
  Index: mod_cgi.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/generators/mod_cgi.c,v
  retrieving revision 1.83
  retrieving revision 1.84
  diff -u -d -b -w -u -r1.83 -r1.84
  --- mod_cgi.c	2001/02/05 22:57:21	1.83
  +++ mod_cgi.c	2001/02/06 16:21:12	1.84
  @@ -989,8 +989,9 @@
   
   static void register_hooks(apr_pool_t *p)
   {
  +    static const char * const aszPre[] = { "mod_include.c", NULL };
       ap_hook_handler(cgi_handler, NULL, NULL, APR_HOOK_MIDDLE);
  -    ap_hook_post_config(cgi_post_config, NULL, NULL, APR_HOOK_REALLY_FIRST);
  +    ap_hook_post_config(cgi_post_config, aszPre, NULL, APR_HOOK_REALLY_FIRST);
   }
   
   module AP_MODULE_DECLARE_DATA cgi_module =
  
  
  
  1.68      +3 -1      httpd-2.0/modules/generators/mod_cgid.c
  
  Index: mod_cgid.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/generators/mod_cgid.c,v
  retrieving revision 1.67
  retrieving revision 1.68
  diff -u -d -b -w -u -r1.67 -r1.68
  --- mod_cgid.c	2001/02/05 22:57:21	1.67
  +++ mod_cgid.c	2001/02/06 16:21:14	1.68
  @@ -1259,7 +1259,9 @@
   
   static void register_hook(apr_pool_t *p)
   {
  -    ap_hook_post_config(cgid_init, NULL, NULL, APR_HOOK_MIDDLE);
  +    static const char * const aszPre[] = { "mod_include.c", NULL };
  +
  +    ap_hook_post_config(cgid_init, aszPre, NULL, APR_HOOK_MIDDLE);
       ap_hook_handler(cgid_handler, NULL, NULL, APR_HOOK_MIDDLE);
   }
   
  
  
  
  1.24      +1 -15     apr-util/buckets/apr_buckets_heap.c
  
  Index: apr_buckets_heap.c
  ===================================================================
  RCS file: /home/cvs/apr-util/buckets/apr_buckets_heap.c,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -d -b -w -u -r1.23 -r1.24
  --- apr_buckets_heap.c	2001/01/19 07:02:00	1.23
  +++ apr_buckets_heap.c	2001/02/06 16:21:17	1.24
  @@ -58,20 +58,6 @@
   #include <strings.h>
   #endif
   
  -/*
  - * The size of heap bucket memory allocations.
  - * XXX: This is currently a guess and should be adjusted to an
  - * empirically good value.
  - */
  -#ifndef DEFAULT_BUCKET_SIZE
  -#define DEFAULT_BUCKET_SIZE (4096)
  -#endif
  -
  -#ifndef max
  -#define max(x,y) \
  -((x) >= (y) ? (x) : (y))
  -#endif
  -
   static apr_status_t heap_read(apr_bucket *b, const char **str, 
   			      apr_size_t *len, apr_read_type_e block)
   {
  @@ -106,7 +92,7 @@
       }
   
       if (copy) {
  -	h->alloc_len = max(DEFAULT_BUCKET_SIZE, length);
  +	h->alloc_len = length;
   	h->base = malloc(h->alloc_len);
   	if (h->base == NULL) {
   	    free(h);
  
  
  

Mime
View raw message