You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jmeter-dev@jakarta.apache.org by se...@apache.org on 2007/03/17 20:22:27 UTC

svn commit: r519420 - in /jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler: HTTPSampler2.java HTTPSamplerBase.java

Author: sebb
Date: Sat Mar 17 12:22:26 2007
New Revision: 519420

URL: http://svn.apache.org/viewvc?view=rev&rev=519420
Log:
HttpClient sampler was checking the wrong header for gzipped content

Modified:
    jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java
    jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSamplerBase.java

Modified: jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java
URL: http://svn.apache.org/viewvc/jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java?view=diff&rev=519420&r1=519419&r2=519420
==============================================================================
--- jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java (original)
+++ jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java Sat Mar 17 12:22:26 2007
@@ -581,7 +581,7 @@
             
             if (instream != null) {// will be null for HEAD
             
-                Header responseHeader = httpMethod.getResponseHeader(TRANSFER_ENCODING);
+                Header responseHeader = httpMethod.getResponseHeader(HEADER_CONTENT_ENCODING);
                 if (responseHeader!= null && ENCODING_GZIP.equals(responseHeader.getValue())) {
                     instream = new GZIPInputStream(instream);
                 }

Modified: jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSamplerBase.java
URL: http://svn.apache.org/viewvc/jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSamplerBase.java?view=diff&rev=519420&r1=519419&r2=519420
==============================================================================
--- jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSamplerBase.java (original)
+++ jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSamplerBase.java Sat Mar 17 12:22:26 2007
@@ -54,7 +54,6 @@
 import org.apache.log.Logger;
 import org.apache.oro.text.MalformedCachePatternException;
 import org.apache.oro.text.regex.Pattern;
-import org.apache.oro.text.regex.Perl5Compiler;
 import org.apache.oro.text.regex.Perl5Matcher;
 
 /**
@@ -189,6 +188,8 @@
     protected static final String KEEP_ALIVE = "keep-alive"; // $NON-NLS-1$
 
     protected static final String TRANSFER_ENCODING = "transfer-encoding";
+
+    protected static final String HEADER_CONTENT_ENCODING = "content-encoding";
 
     protected static final String HTTP_1_1 = "HTTP/1.1"; // $NON-NLS-1$
 



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