Declaration helper macro to construct apr_foo_pool_get()s.
This standardized macro is used by opaque (APR) data types to return
the apr_pool_t that is associated with the data type.
APR_POOL_DECLARE_ACCESSOR() is used in a header file to declare the
accessor function. A typical usage and result would be:
APR_POOL_DECLARE_ACCESSOR(file);
becomes:
APR_DECLARE(apr_pool_t *) apr_file_pool_get(const apr_file_t *thefile);
@remark Doxygen unwraps this macro (via doxygen.conf) to provide
actual help for each specific occurrence of apr_foo_pool_get.
@remark the linkage is specified for APR. It would be possible to expand
the macros to support other linkages.
Implementation helper macro to provide apr_foo_pool_get()s.
In the implementation, the APR_POOL_IMPLEMENT_ACCESSOR() is used to
actually define the function. It assumes the field is named "pool".
Pool debug levels
| 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
---------------------------------
| | | | | | | | x | General debug code enabled (useful in
combination with --with-efence).
| | | | | | | x | | Verbose output on stderr (report
CREATE, CLEAR, DESTROY).
| | | | x | | | | | Verbose output on stderr (report
PALLOC, PCALLOC).
| | | | | | x | | | Lifetime checking. On each use of a
pool, check its lifetime. If the pool
is out of scope, abort().
In combination with the verbose flag
above, it will output LIFE in such an
event prior to aborting.
| | | | | x | | | | Pool owner checking. On each use of a
pool, check if the current thread is the
pool's owner. If not, abort(). In
combination with the verbose flag above,
it will output OWNER in such an event
prior to aborting. Use the debug
function apr_pool_owner_set() to switch
a pool's ownership.
When no debug level was specified, assume general debug mode.
If level 0 was specified, debugging is switched off.
the place in the code where the particular function was called
A function that is called when allocation fails.