Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4121358

compile test code under /test throws StringIndexOutOfBoundsException.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 1.1.7
    • 1.1.6, 1.2.0
    • core-libs
    • b01
    • generic, x86, sparc
    • generic, solaris_2.5.1, windows_95, windows_nt
    • Not verified

        JDK1.1.6(K) or JDK1.2b3(L) comes with test code for regression test under directory ./test in source distribution.

        STEPS:

        $ setenv LANG ja
        $ cd test/java/intltest
        $ javac BreakIteratorTest.java
        java.lang.StringIndexOutOfBoundsException: String index out of range: -125
                at java.lang.String.charAt(String.java:392)
                at sun.io.ByteToCharEUC_JP.getUnicode(ByteToCharEUC_JP.java:72)
                at sun.io.ByteToCharEUC_JP.convert(ByteToCharEUC_JP.java:150)
                at java.io.InputStreamReader.convertInto(InputStreamReader.java:123)
                at java.io.InputStreamReader.fill(InputStreamReader.java:171)
                at java.io.InputStreamReader.read(InputStreamReader.java:229)
                at java.io.Reader.read(Reader.java:103)
                at sun.tools.java.ScannerInputReader.read(ScannerInputReader.java:129)
                at sun.tools.java.Scanner.scanIdentifier(Scanner.java:735)
                at sun.tools.java.Scanner.xscan(Scanner.java:1094)
                at sun.tools.java.Scanner.scan(Scanner.java:784)
                at sun.tools.java.Parser.scan(Parser.java:2024)
                at sun.tools.java.Parser.expect(Parser.java:290)
                at sun.tools.java.Parser.parseStatement(Parser.java:1282)
                at sun.tools.java.Parser.parseBlockStatement(Parser.java:1312)
                at sun.tools.java.Parser.parseStatement(Parser.java:908)
                at sun.tools.java.Parser.parseField(Parser.java:1640)
                at sun.tools.java.Parser.parseClassBody(Parser.java:1872)
                at sun.tools.java.Parser.parseNamedClass(Parser.java:1808)
                at sun.tools.java.Parser.parseClass(Parser.java:1761)
                at sun.tools.java.Parser.parseFile(Parser.java:1968)
                at sun.tools.javac.BatchEnvironment.parseFile(BatchEnvironment.java:343)
                at sun.tools.javac.Main.compile(Main.java:330)
                at sun.tools.javac.Main.main(Main.java:571)

        -----

        This does not happen on "C" Locale.

        koushi.takahashi@japan 1998-03-20

              bcbeck Brian Beck (Inactive)
              ktakahassunw Koushi Takahashi (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: