hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg Kalnichevski <ol...@apache.org>
Subject Re: Strange SSL error
Date Tue, 30 Jun 2015 15:15:13 GMT
On Fri, 2015-06-26 at 18:07 +0000, Mark A. Claassen wrote:
> This is from a pretty old thread, but I was called away for a bit.
> > With chunk coded content the end of stream should be generated when the closing
chunk has been read. It looks like your application either does not read the closing chunk
for some reason or something is still amiss.
> I know the size of the transmission before it goes on the socket, but not soon enough
to put it in the Http header.  So, I know the exact number of bytes and read exactly that
many.  Looking at the EOFSensorInputStream, it looks like it may be helpful for me to call
read() one extra time so that the read() on the input stream returns a -1 at some point.
> Would this be advisable?  Or is it ok for me to read just the exact number of bytes I
know are there and then close my stream (without read ever returning -1)

It would. Generally I would consider reading to the end of message
content stream a good practice.


To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org

View raw message