You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@geronimo.apache.org by "Pieper, Aaron (SAIC)" <Pi...@Pragmatics.com> on 2008/05/15 22:45:47 UTC

Unexpected behavior from QuotedPrintableDecoderStream?

It looks to me like QuotedPrintableDecoderStream's read() method doesn't
look like it fulfills the contract from InputStream. InputStream says it
will return -1 when there is no more data to be read. However,
QuotedPrintableDecoderStream returns 0 in this case. The result is that
IOUtils.copy() in commons-io will go into an endless loop if it's fed a
QuotedPrintableDecoderStream.

 

Should I go ahead and report this in JIRA?

 

- Aaron


Re: Unexpected behavior from QuotedPrintableDecoderStream?

Posted by Rick McGuire <ri...@gmail.com>.
Pieper, Aaron (SAIC) wrote:
>
> It looks to me like QuotedPrintableDecoderStream’s read() method 
> doesn’t look like it fulfills the contract from InputStream. 
> InputStream says it will return -1 when there is no more data to be 
> read. However, QuotedPrintableDecoderStream returns 0 in this case. 
> The result is that IOUtils.copy() in commons-io will go into an 
> endless loop if it’s fed a QuotedPrintableDecoderStream.
>
> Should I go ahead and report this in JIRA?
>
Yes, please do.

> - Aaron
>