httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r..@locus.apache.org
Subject cvs commit: apache-2.0/src/lib/apr/lib apr_pools.c
Date Mon, 28 Feb 2000 19:14:35 GMT
rbb         00/02/28 11:14:35

  Modified:    src/lib/apr/lib apr_pools.c
  Log:
  Check return code from ap_create_lock.
  Submitted by:	Jeff Trawick
  Reviewed by:	Ryan Bloom
  
  Revision  Changes    Path
  1.32      +6 -2      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.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- apr_pools.c	2000/01/28 04:21:55	1.31
  +++ apr_pools.c	2000/02/28 19:14:35	1.32
  @@ -558,16 +558,20 @@
   
   ap_pool_t *ap_init_alloc(void)
   {
  +    ap_status_t status1, status2;
   #ifdef POOL_DEBUG
       char s;
   
       known_stack_point = &s;
       stack_var_init(&s);
   #endif
  -    ap_create_lock(&alloc_mutex, APR_MUTEX, APR_INTRAPROCESS,
  +    status1 = ap_create_lock(&alloc_mutex, APR_MUTEX, APR_INTRAPROCESS,
                      NULL, NULL);
  -    ap_create_lock(&spawn_mutex, APR_MUTEX, APR_INTRAPROCESS,
  +    status2 = ap_create_lock(&spawn_mutex, APR_MUTEX, APR_INTRAPROCESS,
                      NULL, NULL);
  +    if (status1 != APR_SUCCESS || status2 != APR_SUCCESS) {
  +        return NULL;
  +    }
   
       permanent_pool = ap_make_sub_pool(NULL, NULL);
   #ifdef ALLOC_STATS
  
  
  

Mime
View raw message