bnicholes    2003/12/09 09:44:56

  Modified:    memory/unix Tag: APR_0_9_BRANCH apr_pools.c
  Log:
  Since all NetWare memory is shared, allowing an application access to the APR 
global pool allows it to allocate memory and set cleanups that will never 
happen even if the application terminates.
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.197.2.5 +7 -0      apr/memory/unix/apr_pools.c
  
  Index: apr_pools.c
  ===================================================================
  RCS file: /home/cvs/apr/memory/unix/apr_pools.c,v
  retrieving revision 1.197.2.4
  retrieving revision 1.197.2.5
  diff -u -r1.197.2.4 -r1.197.2.5
  --- apr_pools.c       30 Oct 2003 11:39:36 -0000      1.197.2.4
  +++ apr_pools.c       9 Dec 2003 17:44:56 -0000       1.197.2.5
  @@ -1788,6 +1788,13 @@
   
   APR_DECLARE(apr_pool_t *) apr_pool_parent_get(apr_pool_t *pool)
   {
  +#ifdef NETWARE
  +    /* On NetWare, don't return the global_pool, return the application pool 
  +       as the top most pool */
  +    if (pool->parent == global_pool)
  +        return NULL;
  +    else
  +#endif
       return pool->parent;
   }
   
  
  
  

Reply via email to