https://issues.apache.org/bugzilla/show_bug.cgi?id=47645


Jeff Trawick <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|All                         |APR
            Version|2.2.12                      |1.3.4
         AssignedTo|[email protected]       |[email protected]
            Product|Apache httpd-2              |APR


--- Comment #11 from Jeff Trawick <[email protected]> 2009-08-19 11:33:44 PDT 
---
I was able to reproduce the event port problem then run successfully with this
patch, which applies cleanly to the APR in httpd 2.2.12 or 2.2.13.  (It isn't
expected to be needed for httpd older than 2.2.12, unless a certain prefork MPM
fix has been applied on top of 2.2.11).

----------cut here-----------
--- poll/unix/port.c.orig    2009-08-19 13:48:22.876217458 -0400
+++ poll/unix/port.c    2009-08-19 13:49:49.908294412 -0400
@@ -320,6 +320,17 @@
     ret = port_getn(pollset->port_fd, pollset->port_set, pollset->nalloc,
                     &nget, tvptr);

+    if (ret == -1 && nget > 0) {
+        /* On at least some levels of Solaris, -1/ETIME can be
+         * reported at the same time an event is returned.
+         * Since the kernel forgets the event condition as soon as
+         * it is returned, we have to ignore the -1/ETIME and
+         * process the event to prevent a deadlock.
+         */
+
+        ret = 0;
+    }
+
     /* decrease the waiting ASAP to reduce the window for calling 
        port_associate within apr_pollset_add() */
     apr_atomic_dec32(&pollset->waiting);
------------cut here-----------

If anyone tries this patch, please report back.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to