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

javac: malformed input outputs 'I/O Exception' javac: malformed input outputs 'I

XMLWordPrintable

    • 1.2alpha2
    • generic
    • generic
    • Not verified

      When javac tries to report 'Malformed Input Character Encoding,'
      javac reports only 'I/O Exception.'

      for example:
      ------
      % javac InvalidEncodingChar.java
      I/O exception
      %
      ------
      Cause:
      src/share/sun/sun/tools/javac/BatchEnvironment.java#706-
      -----
              } catch (IOException e) {
                  output("I/O exception");
              }
      -----
      and MalformedInputException is a subclass of IOException.

      When MalformedInputException raises in Parser, Invalid Encoding Char
      error is reported thru BatchEnvironment#flushErrors(), shown above.
      This method uses Reader to get line from source (fixed by Naoyuki),
      and Reader raises MalformedInputException again -- at this time,
      this exception makes compiler prints only "I/O exception".

            dstoutamsunw David Stoutamire (Inactive)
            sishidasunw Shoji Ishida (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: