Hi,

I found a problem with GZIP input stream when wrapping InputStream
from HttpURLConnection. When the server response with Transfer-
Encoding=chunked, Content-Encoding=gzip and Connection=Keep-Alive. The
second post always return -1.

After digging into the source code, I found the place that could be a
bug:
  InflaterInputStream.java (line 190 to 192)
              if (inf.needsInput()) {
                   fill();
               }

Because InflaterInputStream doesn't need more input, it doesn't try to
read the end of chunked encoding (0x)(30 0a 0d) that cause the second
post to return with -1 every time. Does anybody have the same issue?

Thanks,

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to