Return-Path: Delivered-To: apmail-apr-cvs-archive@www.apache.org Received: (qmail 75574 invoked from network); 12 Dec 2003 12:17:58 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 12 Dec 2003 12:17:58 -0000 Received: (qmail 26832 invoked by uid 500); 12 Dec 2003 12:17:56 -0000 Delivered-To: apmail-apr-cvs-archive@apr.apache.org Received: (qmail 26780 invoked by uid 500); 12 Dec 2003 12:17:56 -0000 Mailing-List: contact cvs-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Reply-To: dev@apr.apache.org Delivered-To: mailing list cvs@apr.apache.org Received: (qmail 26766 invoked from network); 12 Dec 2003 12:17:56 -0000 Date: 12 Dec 2003 12:17:57 -0000 Message-ID: <20031212121757.75522.qmail@minotaur.apache.org> From: striker@apache.org To: apr-cvs@apache.org Subject: cvs commit: apr/include apr_pools.h X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N striker 2003/12/12 04:17:56 Modified: include apr_pools.h Log: Clarify what is and isn't safe to do with cleanups. Revision Changes Path 1.110 +6 -1 apr/include/apr_pools.h Index: apr_pools.h =================================================================== RCS file: /home/cvs/apr/include/apr_pools.h,v retrieving revision 1.109 retrieving revision 1.110 diff -u -r1.109 -r1.110 --- apr_pools.h 3 Nov 2003 17:00:15 -0000 1.109 +++ apr_pools.h 12 Dec 2003 12:17:56 -0000 1.110 @@ -514,7 +514,12 @@ * Cleanup * * Cleanups are performed in the reverse order they were registered. That is: - * Last In, First Out. + * Last In, First Out. A cleanup function can safely allocate memory from + * the pool that is being cleaned up. It can also safely register additional + * cleanups which will be run LIFO, directly after the current cleanup + * terminates. Cleanups have to take caution in calling functions that + * create subpools. Subpools, created during cleanup will NOT automatically + * be cleaned up. In other words, cleanups are to clean up after themselves. */ /**