apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From traw...@apache.org
Subject svn commit: r829801 - /apr/apr/branches/1.4.x/poll/unix/port.c
Date Mon, 26 Oct 2009 13:53:35 GMT
Author: trawick
Date: Mon Oct 26 13:53:35 2009
New Revision: 829801

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

Work around bogus return code in some circumstances with 32-bit
port_getn() on Solaris 10 x86.

AFAICT this problem only occurs when the return code should be
zero, so changing the return code check should be sufficient.

APR 1.3.8 wasn't affected.

PR: 48029

Modified:
    apr/apr/branches/1.4.x/poll/unix/port.c

Modified: apr/apr/branches/1.4.x/poll/unix/port.c
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.4.x/poll/unix/port.c?rev=829801&r1=829800&r2=829801&view=diff
==============================================================================
--- apr/apr/branches/1.4.x/poll/unix/port.c (original)
+++ apr/apr/branches/1.4.x/poll/unix/port.c Mon Oct 26 13:53:35 2009
@@ -104,8 +104,11 @@
     }
 
     ret = port_getn(port, list, max, nget, tvptr);
+    /* Note: 32-bit port_getn() on Solaris 10 x86 returns large negative 
+     * values instead of 0 when returning immediately.
+     */
 
-    if (ret < 0) {
+    if (ret == -1) {
         rv = apr_get_netos_error();
 
         switch(rv) {



Mime
View raw message