cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1237633 - /cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
Date Mon, 30 Jan 2012 13:04:31 GMT
Author: sergeyb
Date: Mon Jan 30 13:04:31 2012
New Revision: 1237633

URL: http://svn.apache.org/viewvc?rev=1237633&view=rev
Log:
Attempting to capture a case when the response code may be corrupted

Modified:
    cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java

Modified: cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java?rev=1237633&r1=1237632&r2=1237633&view=diff
==============================================================================
--- cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
(original)
+++ cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
Mon Jan 30 13:04:31 2012
@@ -1557,8 +1557,10 @@ public class HTTPConduit 
         protected void handleResponseInternal() throws IOException {
             Exchange exchange = outMessage.getExchange();
             int responseCode = connection.getResponseCode();
-            
-            if (outMessage != null && exchange != null) {
+            if (responseCode == -1) {
+                LOG.warning("HTTP Response code appears to be corrupted");
+            }
+            if (exchange != null) {
                 exchange.put(Message.RESPONSE_CODE, responseCode);
             }
             



Mime
View raw message