diff options
author | Yann Ylavic <ylavic@apache.org> | 2022-02-02 10:18:41 +0000 |
---|---|---|
committer | Yann Ylavic <ylavic@apache.org> | 2022-02-02 10:18:41 +0000 |
commit | ba426a54895ab1bb3f03a7fe4489420ef9195485 (patch) | |
tree | ae89292abf6e18fba6212f67f9bd6d3f97f38cf4 | |
parent | 7833dc9148c549040eee27ddc90dda8cf28dcf4d (diff) | |
download | httpd-ba426a54895ab1bb3f03a7fe4489420ef9195485.tar.gz |
core: Follow up to r1897240: Provide/export ap_thread_current_create()
For completness, and possibly to ease backport to 2.4.x for MPM winnt.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1897691 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | include/httpd.h | 4 | ||||
-rw-r--r-- | server/util.c | 6 |
2 files changed, 7 insertions, 3 deletions
diff --git a/include/httpd.h b/include/httpd.h index 86456d4afd..b8f6119329 100644 --- a/include/httpd.h +++ b/include/httpd.h @@ -2579,6 +2579,7 @@ AP_DECLARE(void *) ap_realloc(void *ptr, size_t size) #endif #define ap_thread_create apr_thread_create #define ap_thread_current apr_thread_current +#define ap_thread_current_create apr_thread_current_create #define ap_thread_current_after_fork apr_thread_current_after_fork #else /* APR_VERSION_AT_LEAST(1,8,0) && !defined(AP_NO_THREAD_LOCAL) */ @@ -2609,6 +2610,9 @@ AP_DECLARE(apr_status_t) ap_thread_create(apr_thread_t **thread, void *data, apr_pool_t *pool); #endif /* AP_THREAD_LOCAL */ +AP_DECLARE(apr_status_t) ap_thread_current_create(apr_thread_t **current, + apr_threadattr_t *attr, + apr_pool_t *pool) AP_DECLARE(void) ap_thread_current_after_fork(void); AP_DECLARE(apr_thread_t *) ap_thread_current(void); diff --git a/server/util.c b/server/util.c index 7c2fa87cfd..2018396e5a 100644 --- a/server/util.c +++ b/server/util.c @@ -3300,9 +3300,9 @@ AP_DECLARE(apr_status_t) ap_thread_create(apr_thread_t **thread, #endif /* AP_HAS_THREAD_LOCAL */ -static apr_status_t ap_thread_current_create(apr_thread_t **current, - apr_threadattr_t *attr, - apr_pool_t *pool) +AP_DECLARE(apr_status_t) ap_thread_current_create(apr_thread_t **current, + apr_threadattr_t *attr, + apr_pool_t *pool) { apr_status_t rv; apr_abortfunc_t abort_fn = apr_pool_abort_get(pool); |