tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mt...@apache.org
Subject svn commit: r893419 - /tomcat/jk/trunk/native/common/jk_connect.c
Date Wed, 23 Dec 2009 07:50:04 GMT
Author: mturk
Date: Wed Dec 23 07:50:03 2009
New Revision: 893419

URL: http://svn.apache.org/viewvc?rev=893419&view=rev
Log:
Use DEBUG instead WARN. Later we log that as INFO anyhow

Modified:
    tomcat/jk/trunk/native/common/jk_connect.c

Modified: tomcat/jk/trunk/native/common/jk_connect.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/common/jk_connect.c?rev=893419&r1=893418&r2=893419&view=diff
==============================================================================
--- tomcat/jk/trunk/native/common/jk_connect.c (original)
+++ tomcat/jk/trunk/native/common/jk_connect.c Wed Dec 23 07:50:03 2009
@@ -850,9 +850,9 @@
         } while (JK_IS_SOCKET_ERROR(rd) && errno == EINTR);
 
         if (JK_IS_SOCKET_ERROR(rd)) {
+            rd = (errno > 0) ? -errno : errno;
             jk_shutdown_socket(sd, l);
             JK_TRACE_EXIT(l);
-            rd = (errno > 0) ? -errno : errno;
             return (rd == 0) ? JK_SOCKET_EOF : rd;
         }
         else if (rd == 0) {
@@ -906,6 +906,7 @@
     errno = 0;
     fds.fd = sd;
     fds.events = POLLIN;
+    fds.revents = 0;
 
     do {
         rc = poll(&fds, 1, timeout);
@@ -919,17 +920,21 @@
     }
     else if (rc < 0) {
         save_errno = errno;
-        jk_log(l, JK_LOG_WARNING,
-               "error during poll on socket sd = %d (errno=%d)", sd, errno);
+        if (JK_IS_DEBUG_LEVEL(l)) {
+            jk_log(l, JK_LOG_DEBUG,
+                   "error during poll on socket sd = %d (errno=%d)", sd, errno);
+        }
         errno = save_errno;
         JK_TRACE_EXIT(l);
         return JK_FALSE;
     }
     if ((fds.revents & (POLLERR | POLLHUP))) {
         save_errno = fds.revents & (POLLERR | POLLHUP);
-        jk_log(l, JK_LOG_WARNING,
-               "error event during poll on socket sd = %d (event=%d)",
+        if (JK_IS_DEBUG_LEVEL(l)) {
+            jk_log(l, JK_LOG_DEBUG,
+                   "error event during poll on socket sd = %d (event=%d)",
                sd, save_errno);
+        }
         errno = save_errno;
         JK_TRACE_EXIT(l);
         return JK_FALSE;        
@@ -970,8 +975,11 @@
     }
     else if (rc < 0) {
         save_errno = errno;
-        jk_log(l, JK_LOG_WARNING,
-               "error during select on socket sd = %d (errno=%d)", sd, errno);
+        if (JK_IS_DEBUG_LEVEL(l)) {
+            jk_log(l, JK_LOG_DEBUG,
+                   "error during select on socket sd = %d (errno=%d)",
+                   sd, errno);
+        }
         errno = save_errno;
         JK_TRACE_EXIT(l);
         return JK_FALSE;



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message