on-internet
← Community

How to exit an APR thread with a specific error code

Stack Overflow ·

I have a thread in APR static void *APR_THREAD_FUNC processing_thread(apr_thread_t *thptr,void *arg) { //do processing return NULL; } And then I create this thread like this: apr_status_t status; apr_thread_t *thread; thread_data_t data; apr_pool_t *pool; apr_pool_create(&pool,NULL); status = apr_thread_create(&thread,NULL,processing_thread,&data,pool) //do other stuff apr_thread_join(&status, thread); When I call apr_thread_join later, how can I in the processing_thread return an error code if there is an error inside the thread?

Comments

Sign in or sign up to comment and upvote.

No comments yet.