diff options
author | Justin Erenkrantz <jerenkrantz@apache.org> | 2002-02-16 19:35:21 +0100 |
---|---|---|
committer | Justin Erenkrantz <jerenkrantz@apache.org> | 2002-02-16 19:35:21 +0100 |
commit | 39b3c29d1ee7ce61def7bb05fe0794bacb81b404 (patch) | |
tree | 97dc27ac6fa5670a7e7bb92695d4c8e8710a410c /modules/ssl/ssl_engine_mutex.c | |
parent | This comment is bogus since we decided to keep -X. (diff) | |
download | apache2-39b3c29d1ee7ce61def7bb05fe0794bacb81b404.tar.xz apache2-39b3c29d1ee7ce61def7bb05fe0794bacb81b404.zip |
If the file specified by SSLMutex cannot be created (because the directory does not exist for example), children will segfault on init without giving any reason that the user can figure out. This happens because the module init in the parent never checks to see if the mutex intialization succeded. This patch adds this check and a user-friendly error message.
(Justin made one formatting change to this patch.)
Submitted by: Adam Sussman <myddryn@vishnu.vidya.com>
Reviewed by: Justin Erenkrantz
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93441 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'modules/ssl/ssl_engine_mutex.c')
-rw-r--r-- | modules/ssl/ssl_engine_mutex.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/modules/ssl/ssl_engine_mutex.c b/modules/ssl/ssl_engine_mutex.c index 8164d28b69..fb0f06b413 100644 --- a/modules/ssl/ssl_engine_mutex.c +++ b/modules/ssl/ssl_engine_mutex.c @@ -70,8 +70,12 @@ int ssl_mutex_init(server_rec *s, apr_pool_t *p) return TRUE; if (apr_lock_create(&mc->pMutex, APR_MUTEX, APR_LOCKALL, APR_LOCK_DEFAULT, - mc->szMutexFile, p) != APR_SUCCESS) + mc->szMutexFile, p) != APR_SUCCESS) { + ssl_log(s, SSL_LOG_CRIT|SSL_ADD_ERRNO, + "Cannot create SSLMutex file `%s'", + mc->szMutexFile); return FALSE; + } return TRUE; } |