]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Merge r1629577 from trunk:
authorJim Jagielski <jim@apache.org>
Mon, 27 Oct 2014 12:46:45 +0000 (12:46 +0000)
committerJim Jagielski <jim@apache.org>
Mon, 27 Oct 2014 12:46:45 +0000 (12:46 +0000)
event: Fix worker-listener deadlock in graceful restart caused by get_worker()
allocating new worker after ap_queue_info_term(), but not setting the
have_idle_worker variable. PR 56960.

Submitted By: Zin UDA
Committed By: jkaluza

Submitted by: jkaluza
Reviewed/backported by: jim

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1634526 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
STATUS
server/mpm/event/event.c

diff --git a/CHANGES b/CHANGES
index d5410705f96735a8d570cde2dd3abc6b59fa1b77..6b1d9b5d4bc79cb964e414432521f941696a967f 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -2,6 +2,9 @@
 
 Changes with Apache 2.4.11
 
+  *) event: Fix worker-listener deadlock in graceful restart.
+     PR 56960.
+
   *) Concat strings at compile time when possible. PR 53741.
 
   *) mod_substitute: Restrict configuration in .htaccess to
diff --git a/STATUS b/STATUS
index e06f637ad540d61580145c26ba5151119a873ff5..e4ba2e3c7630527a0ed9631ba94ee48913e7a8a7 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -102,13 +102,6 @@ RELEASE SHOWSTOPPERS:
 PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
   [ start all new proposals below, under PATCHES PROPOSED. ]
 
-   * event: Fix worker-listener deadlock in graceful restart caused by
-     get_worker() allocating new worker after ap_queue_info_term(),
-     but not setting the have_idle_worker variable. PR 56960.
-     trunk patch: http://svn.apache.org/r1629577
-     2.4.x patch: trunk works
-     +1: jkaluza, ylavic, jim
-
    * mod_cache_socache: Add cache status to server-status.
      The status_hook simply calls the status function of
      socache, very much like mod_ssl does for the ssl
index ee92237e5af87546893a485008077a2fed0e9ac8..82e7d11c4e345b09c84141d04b17c4ea4e1adfb9 100644 (file)
@@ -1271,13 +1271,13 @@ static void get_worker(int *have_idle_worker_p, int blocking, int *all_busy)
     else
         rc = ap_queue_info_try_get_idler(worker_queue_info);
 
-    if (rc == APR_SUCCESS) {
+    if (rc == APR_SUCCESS || APR_STATUS_IS_EOF(rc)) {
         *have_idle_worker_p = 1;
     }
     else if (!blocking && rc == APR_EAGAIN) {
         *all_busy = 1;
     }
-    else if (!APR_STATUS_IS_EOF(rc)) {
+    else {
         ap_log_error(APLOG_MARK, APLOG_ERR, rc, ap_server_conf, APLOGNO(00472)
                      "ap_queue_info_wait_for_idler failed.  "
                      "Attempting to shutdown process gracefully");