summaryrefslogtreecommitdiffstats
path: root/server/mpm_common.c
diff options
context:
space:
mode:
authorStefan Fritsch <sf@apache.org>2010-08-21 20:06:41 +0200
committerStefan Fritsch <sf@apache.org>2010-08-21 20:06:41 +0200
commit8f840cb763aa67f331cecc4e5e850bb07d2a9943 (patch)
treef849def8fc48e41a7b682b7da935607eb94f15dd /server/mpm_common.c
parentfollow up r987629 with another similar issue (diff)
downloadapache2-8f840cb763aa67f331cecc4e5e850bb07d2a9943.tar.xz
apache2-8f840cb763aa67f331cecc4e5e850bb07d2a9943.zip
core: Abort with sensible error message if no or more than one MPM is
loaded. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@987806 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'server/mpm_common.c')
-rw-r--r--server/mpm_common.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/server/mpm_common.c b/server/mpm_common.c
index 56bc70c875..e45a089447 100644
--- a/server/mpm_common.c
+++ b/server/mpm_common.c
@@ -375,3 +375,13 @@ AP_DECLARE(const char *)ap_show_mpm(void)
return name;
}
+
+AP_DECLARE(const char *)ap_check_mpm(void)
+{
+ if (!_hooks.link_mpm || _hooks.link_mpm->nelts == 0)
+ return "No MPM loaded.";
+ else if (_hooks.link_mpm->nelts > 1)
+ return "More than one MPM loaded.";
+ else
+ return NULL;
+}