StAX
  1. StAX
  2. STAX-37

MXParser.setInput(InputStream) contains unaccessible code

    Details

    • Type: Bug Bug
    • Status: Open Open
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Labels:
      None
    • Number of attachments :
      0

      Description

      MXParser.setInput(InputStream) contains the following code snippet:

      ...
      Reader r = XmlReader.createReader(in);
      /* 07-Mar-2006, TSa: Let's figure out encoding we detected

      • (whether based on xml declaration, BOM, or recognized
      • signature)...
        */
        String enc = null;
        if (r instanceof XmlReader.BaseReader) { enc = ((XmlReader.BaseReader) r).getEncoding(); }

        ...

      However, XmlReader.createReader(InputStream) currently just returns a new XmlReader object. Unless I am being silly, I can't see that r will ever be instanceof XmlReader.BaseReader. Stepping through the code seems to verify this.

        Activity

        No changes have yet been made on this issue.

          People

          • Assignee:
            Unassigned
            Reporter:
            Bob Arthur
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated: