File tree Expand file tree Collapse file tree
src/test/java/org/apache/commons/io/input Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -418,8 +418,18 @@ private void testAvailableRead(final String csName) throws Exception {
418418 @ Test
419419 public void testAvailable () throws Exception {
420420 for (final String csName : Charset .availableCharsets ().keySet ()) {
421- // prevent java.lang.UnsupportedOperationException at sun.nio.cs.ext.ISO2022_CN.newEncoder.
422- if (Charset .forName (csName ).canEncode ()) {
421+ // prevent java.lang.UnsupportedOperationException at sun.nio.cs.ext.ISO2022_CN.newEncoder.
422+ // also try and avoid the following Effor on Continuum
423+ // java.lang.UnsupportedOperationException: null
424+ // at java.nio.CharBuffer.array(CharBuffer.java:940)
425+ // at sun.nio.cs.ext.COMPOUND_TEXT_Encoder.encodeLoop(COMPOUND_TEXT_Encoder.java:75)
426+ // at java.nio.charset.CharsetEncoder.encode(CharsetEncoder.java:544)
427+ // at org.apache.commons.io.input.CharSequenceInputStream.fillBuffer(CharSequenceInputStream.java:120)
428+ // at org.apache.commons.io.input.CharSequenceInputStream.read(CharSequenceInputStream.java:151)
429+ // at org.apache.commons.io.input.CharSequenceInputStreamTest.testAvailableRead(CharSequenceInputStreamTest.java:412)
430+ // at org.apache.commons.io.input.CharSequenceInputStreamTest.testAvailable(CharSequenceInputStreamTest.java:424)
431+
432+ if (Charset .forName (csName ).canEncode () && ! "COMPOUND_TEXT" .equalsIgnoreCase (csName )) {
423433 testAvailableSkip (csName );
424434 testAvailableRead (csName );
425435 }
You can’t perform that action at this time.
0 commit comments