]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Fix crash in ap_mpm_pod_check call caused by NULL dereference of its parameter
authorJan Kaluža <jkaluza@apache.org>
Fri, 30 Oct 2015 14:07:28 +0000 (14:07 +0000)
committerJan Kaluža <jkaluza@apache.org>
Fri, 30 Oct 2015 14:07:28 +0000 (14:07 +0000)
when starting httpd as single process (httpd -X).

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1711479 13f79535-47bb-0310-9956-ffa450edef68

server/mpm/event/event.c
server/mpm/prefork/prefork.c
server/mpm/worker/worker.c

index 1cdc52c762c6f3a9d39bcfd21ce4e3f31e7cf6cc..b62f51f7830786d3e1b0edf1d366d4237260fba1 100644 (file)
@@ -3329,8 +3329,7 @@ static int event_open_logs(apr_pool_t * p, apr_pool_t * plog,
 
     all_buckets = apr_pcalloc(pconf, num_buckets * sizeof(*all_buckets));
     for (i = 0; i < num_buckets; i++) {
-        if (!one_process && /* no POD in one_process mode */
-                (rv = ap_mpm_podx_open(pconf, &all_buckets[i].pod))) {
+        if (rv = ap_mpm_podx_open(pconf, &all_buckets[i].pod)) {
             ap_log_error(APLOG_MARK, APLOG_CRIT | level_flags, rv,
                          (startup ? NULL : s),
                          "could not open pipe-of-death");
index 78638c80032d8efaec44f7846ab4a00e301cc490..ab925546151cf972a165836970127a0c23f5a402 100644 (file)
@@ -1328,8 +1328,7 @@ static int prefork_open_logs(apr_pool_t *p, apr_pool_t *plog, apr_pool_t *ptemp,
     all_buckets = apr_pcalloc(pconf, num_buckets *
                                      sizeof(prefork_child_bucket));
     for (i = 0; i < num_buckets; i++) {
-        if (!one_process && /* no POD in one_process mode */
-                (rv = ap_mpm_pod_open(pconf, &all_buckets[i].pod))) {
+        if (rv = ap_mpm_pod_open(pconf, &all_buckets[i].pod)) {
             ap_log_error(APLOG_MARK, APLOG_CRIT | level_flags, rv,
                          (startup ? NULL : s),
                          "could not open pipe-of-death");
index 99399a0981b02f4f300819457cf411ca5ca10945..00fdd78283b0b00b48aadf6ffdc8978dce92db30 100644 (file)
@@ -2053,8 +2053,7 @@ static int worker_open_logs(apr_pool_t *p, apr_pool_t *plog, apr_pool_t *ptemp,
 
     all_buckets = apr_pcalloc(pconf, num_buckets * sizeof(*all_buckets));
     for (i = 0; i < num_buckets; i++) {
-        if (!one_process && /* no POD in one_process mode */
-                (rv = ap_mpm_podx_open(pconf, &all_buckets[i].pod))) {
+        if (rv = ap_mpm_podx_open(pconf, &all_buckets[i].pod)) {
             ap_log_error(APLOG_MARK, APLOG_CRIT | level_flags, rv,
                          (startup ? NULL : s),
                          "could not open pipe-of-death");