You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by tr...@apache.org on 2009/11/17 15:31:39 UTC

svn commit: r881303 - in /apr/apr/branches/1.3.x: CHANGES build/apr_hints.m4

Author: trawick
Date: Tue Nov 17 14:31:39 2009
New Revision: 881303

URL: http://svn.apache.org/viewvc?rev=881303&view=rev
Log:
merge r881301 from trunk:

Solaris 10 or later: Use pthread by default for cross-process mutex instead of
fcntl; the latter is not thread-aware, leading to EDEADLK failures with some multi-
threaded, multi-process applications.

Proper recovery after a crash of the mutex owner was tested on Solaris 10 U5 and
OpenSolaris 2009.06.  Earlier Solaris versions weren't tested, and there were
reports in httpd-land long ago about failures to recover the mutex.

Modified:
    apr/apr/branches/1.3.x/CHANGES
    apr/apr/branches/1.3.x/build/apr_hints.m4

Modified: apr/apr/branches/1.3.x/CHANGES
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.3.x/CHANGES?rev=881303&r1=881302&r2=881303&view=diff
==============================================================================
--- apr/apr/branches/1.3.x/CHANGES [utf-8] (original)
+++ apr/apr/branches/1.3.x/CHANGES [utf-8] Tue Nov 17 14:31:39 2009
@@ -1,6 +1,11 @@
                                                      -*- coding: utf-8 -*-
 Changes for APR 1.3.10
 
+  *) Solaris 10 and later: Change the default cross-mutex mechanism from
+     fcntl to pthread to resolve EDEADLK failures with some multi-threaded,
+     multi-process applications (e.g., httpd's worker MPM with certain
+     plug-in modules).  [Jeff Trawick]
+
   *) Solaris pollcb support: Fix a hang in apr_pollcb_poll().
      [Jeff Trawick]
 

Modified: apr/apr/branches/1.3.x/build/apr_hints.m4
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.3.x/build/apr_hints.m4?rev=881303&r1=881302&r2=881303&view=diff
==============================================================================
--- apr/apr/branches/1.3.x/build/apr_hints.m4 (original)
+++ apr/apr/branches/1.3.x/build/apr_hints.m4 Tue Nov 17 14:31:39 2009
@@ -244,7 +244,11 @@
     *-solaris2*)
     	PLATOSVERS=`echo $host | sed 's/^.*solaris2.//'`
 	APR_ADDTO(CPPFLAGS, [-DSOLARIS2=$PLATOSVERS -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT])
-        APR_SETIFNULL(apr_lock_method, [USE_FCNTL_SERIALIZE])
+        if test $PLATOSVERS -ge 10; then
+            APR_SETIFNULL(apr_lock_method, [USE_PROC_PTHREAD_SERIALIZE])
+        else
+            APR_SETIFNULL(apr_lock_method, [USE_FCNTL_SERIALIZE])
+        fi
         # readdir64_r error handling seems broken on Solaris (at least
         # up till 2.8) -- it will return -1 at end-of-directory.
         APR_SETIFNULL(ac_cv_func_readdir64_r, [no])