rbb 01/08/12 21:20:19
Modified: . CHANGES
include apr_pools.h
memory/unix apr_pools.c
Log:
Make all APR pools be allocated out of the permanent pool.
This brings APR pools back to a tree structure. There are
no longer any way to create a pool that is not a decendant
of the permanent_pool.
PR: 7891
Revision Changes Path
1.135 +5 -0 apr/CHANGES
Index: CHANGES
===================================================================
RCS file: /home/cvs/apr/CHANGES,v
retrieving revision 1.134
retrieving revision 1.135
diff -u -r1.134 -r1.135
--- CHANGES 2001/08/10 21:04:46 1.134
+++ CHANGES 2001/08/13 04:20:18 1.135
@@ -1,5 +1,10 @@
Changes with APR b1
+ *) Make all APR pools be allocated out of the permanent pool.
+ This brings APR pools back to a tree structure. There are
+ no longer any way to create a pool that is not a decendant
+ of the permanent_pool. [Ryan Bloom]
+
*) Wrap all functions in APR_DECLARE macro.
[Sterling Hughes <[EMAIL PROTECTED]>]
1.58 +0 -1 apr/include/apr_pools.h
Index: apr_pools.h
===================================================================
RCS file: /home/cvs/apr/include/apr_pools.h,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -r1.57 -r1.58
--- apr_pools.h 2001/08/12 04:31:52 1.57
+++ apr_pools.h 2001/08/13 04:20:19 1.58
@@ -447,7 +447,6 @@
# define apr_pool_join(a,b)
#endif /* APR_POOL_DEBUG */
-
#ifdef APR_POOLS_ARE_SMS
/* Add a number of defines where the sms equivalent is 1 to 1 */
#define apr_pool_get_abort(p) apr_sms_get_abort(p)
1.108 +5 -2 apr/memory/unix/apr_pools.c
Index: apr_pools.c
===================================================================
RCS file: /home/cvs/apr/memory/unix/apr_pools.c,v
retrieving revision 1.107
retrieving revision 1.108
diff -u -r1.107 -r1.108
--- apr_pools.c 2001/08/09 19:33:58 1.107
+++ apr_pools.c 2001/08/13 04:20:19 1.108
@@ -658,10 +658,12 @@
apr_pool_t *parent_pool)
{
apr_abortfunc_t abortfunc;
+ apr_pool_t *ppool;
abortfunc = parent_pool ? parent_pool->apr_abort : NULL;
+ ppool = parent_pool ? parent_pool : permanent_pool;
- apr_pool_sub_make(newpool, parent_pool, abortfunc);
+ apr_pool_sub_make(newpool, ppool, abortfunc);
if (*newpool == NULL) {
return APR_ENOPOOL;
}
@@ -834,7 +836,7 @@
return status;
}
#endif
- apr_pool_sub_make(&permanent_pool, globalp, NULL);
+ permanent_pool = globalp;
#ifdef ALLOC_STATS
atexit(dump_stats);
@@ -1488,3 +1490,4 @@
}
}
}
+