From 6e7e01ca1bd6831441fd4a350fd4af48e7beae6a Mon Sep 17 00:00:00 2001 From: Bojan Smojver Date: Tue, 15 Jul 2008 05:22:35 +0000 Subject: [PATCH] Unlock list mutex before destroying it. Manual page for pthread_mutex_destroy() states: Attempting to destroy a locked mutex results in undefined behavior. git-svn-id: https://svn.eu.apache.org/repos/asf/apr/apr-util/trunk@676800 13f79535-47bb-0310-9956-ffa450edef68 --- misc/apr_reslist.c | 1 + 1 file changed, 1 insertion(+) diff --git a/misc/apr_reslist.c b/misc/apr_reslist.c index 14b7e6c..d26c948 100644 --- a/misc/apr_reslist.c +++ b/misc/apr_reslist.c @@ -158,6 +158,7 @@ static apr_status_t reslist_cleanup(void *data_) assert(rl->nidle == 0); assert(rl->ntotal == 0); + apr_thread_mutex_unlock(rl->listlock); apr_thread_mutex_destroy(rl->listlock); apr_thread_cond_destroy(rl->avail); -- 2.11.4.GIT