Skip to content

Commit 26832d2

Browse files
authored
When a service returns data with deflate encoding "incorrect header check" error was throw (#290)
Issue: 85902
1 parent 5120057 commit 26832d2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

common/src/main/java/HTTPClient/ContentEncodingModule.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434

3535
import java.io.IOException;
3636
import java.util.Vector;
37+
import java.util.zip.Inflater;
3738
import java.util.zip.InflaterInputStream;
3839
import java.util.zip.GZIPInputStream;
3940

@@ -179,7 +180,7 @@ else if (encoding.equalsIgnoreCase("deflate"))
179180
{
180181
Log.write(Log.MODS, "CEM: pushing inflater-input-stream");
181182

182-
resp.inp_stream = new InflaterInputStream(resp.inp_stream);
183+
resp.inp_stream = new InflaterInputStream(resp.inp_stream, new Inflater(true));
183184
pce.removeElementAt(pce.size()-1);
184185
resp.deleteHeader("Content-length");
185186
}

0 commit comments

Comments
 (0)