Repository: camel
Updated Branches:
  refs/heads/camel-2.17.x 6efd0461d -> cef2609c5
  refs/heads/master d943910b2 -> d72b9af01


Check to see if disableStreamCache is enabled before consuming the httpResponse 
entity


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/f918aad6
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/f918aad6
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/f918aad6

Branch: refs/heads/master
Commit: f918aad67d9164fa4764c16e744eb06be22afa34
Parents: d943910
Author: Edward Welch <e...@edjusted.com>
Authored: Wed Apr 6 07:35:10 2016 -0400
Committer: Claus Ibsen <davscl...@apache.org>
Committed: Thu Apr 7 10:30:09 2016 +0200

----------------------------------------------------------------------
 .../main/java/org/apache/camel/component/http4/HttpProducer.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/f918aad6/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpProducer.java
----------------------------------------------------------------------
diff --git 
a/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpProducer.java
 
b/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpProducer.java
index 7622d02..4edc6c5 100644
--- 
a/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpProducer.java
+++ 
b/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpProducer.java
@@ -179,7 +179,7 @@ public class HttpProducer extends DefaultProducer {
                 }
             }
         } finally {
-            if (httpResponse != null) {
+            if (httpResponse != null && !getEndpoint().isDisableStreamCache()) 
{
                 try {
                     EntityUtils.consume(httpResponse.getEntity());
                 } catch (IOException e) {

Reply via email to