diff options
author | Jeff Trawick <trawick@apache.org> | 2011-03-21 14:47:28 +0000 |
---|---|---|
committer | Jeff Trawick <trawick@apache.org> | 2011-03-21 14:47:28 +0000 |
commit | 81a0ee7096379e7973ea1b7b695d483b677dda15 (patch) | |
tree | a72a2ca1be75654a3e0bedd63f94d4b945921c68 /memory | |
parent | d5999f087ef8591f590e59e39e27281a7b146def (diff) | |
download | apr-81a0ee7096379e7973ea1b7b695d483b677dda15.tar.gz |
Merge r892387 from trunk:
Cleanups for various gcc warnings, conditional assignment and type errors
Submitted by: wrowe
Reviewed by: trawick
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.5.x@1083810 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'memory')
-rw-r--r-- | memory/unix/apr_pools.c | 31 |
1 files changed, 20 insertions, 11 deletions
diff --git a/memory/unix/apr_pools.c b/memory/unix/apr_pools.c index 2178ebf44..9ac397791 100644 --- a/memory/unix/apr_pools.c +++ b/memory/unix/apr_pools.c @@ -553,7 +553,6 @@ static apr_file_t *file_stderr = NULL; */ static void run_cleanups(cleanup_t **c); -static void run_child_cleanups(cleanup_t **c); static void free_proc_chain(struct process_chain *procs); #if APR_POOL_DEBUG @@ -2349,6 +2348,8 @@ static void run_cleanups(cleanup_t **cref) } } +#if !defined(WIN32) && !defined(OS2) + static void run_child_cleanups(cleanup_t **cref) { cleanup_t *c = *cref; @@ -2370,20 +2371,28 @@ static void cleanup_pool_for_exec(apr_pool_t *p) APR_DECLARE(void) apr_pool_cleanup_for_exec(void) { -#if !defined(WIN32) && !defined(OS2) + cleanup_pool_for_exec(global_pool); +} + +#else /* !defined(WIN32) && !defined(OS2) */ + +APR_DECLARE(void) apr_pool_cleanup_for_exec(void) +{ /* - * Don't need to do anything on NT or OS/2, because I - * am actually going to spawn the new process - not - * exec it. All handles that are not inheritable, will - * be automajically closed. The only problem is with - * file handles that are open, but there isn't much - * I can do about that (except if the child decides - * to go out and close them + * Don't need to do anything on NT or OS/2, because + * these platforms will spawn the new process - not + * fork for exec. All handles that are not inheritable, + * will be automajically closed. The only problem is + * with file handles that are open, but there isn't + * much that can be done about that (except if the + * child decides to go out and close them, or the + * developer quits opening them shared) */ - cleanup_pool_for_exec(global_pool); -#endif /* !defined(WIN32) && !defined(OS2) */ + return; } +#endif /* !defined(WIN32) && !defined(OS2) */ + APR_DECLARE_NONSTD(apr_status_t) apr_pool_cleanup_null(void *data) { /* do nothing cleanup routine */ |