Details
-
Bug
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
2.8.0
-
None
Description
Neither the class documentation of org.apache.commons.io.input.ReaderInputStream nor the documentation of the constructors taking CharsetEncoder arguments describe whether CharsetEncoder.reset() is called.
Since calling reset() is part of the encoding operation (see CharsetEncoder documentation), it should at least be specified whether this method is called or not.
Additionally it might make sense to call reset() (though this might be a breaking change?) because encoding from a new (?) reader with an already used encoder which is not reset might lead to unexpected and incorrect results.