users@jersey.java.net

[jersey 1.0.3] 'Unexpected end of ZLIB input stream' error with GZIPContentEncod

From: Privalov, Sergey <s.privalov_at_itransition.com>
Date: Wed, 22 Apr 2009 21:30:48 +0300

Hi Paul,

Thank for the quick reply!

I have tried with your fix and it does not work :(
But I think you are right and problem is that GZIPOutputStream.finish is not called, because I have tried with the following hook and it is working:

        @Override
        public void flush() throws IOException {
            out.flush();
            out.finish();
        }

So, looks like that problem in that GZIPOutputStream.close() is not called at all

Best Regards,
Sergey