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

Discrepancy between the methods hasNext() and next() in XMLEventReader

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Not an Issue
    • Affects Version/s: 7u4
    • Fix Version/s: 7u6
    • Component/s: xml

      Description

      During testing we found the case where the method next () and hasNext () do not corresponded to each other. Method hasNext() returns true, but the method of next() throws NoSuchElementException.
      May be xml file is wrong because of the line separator is \r\n , but in any case, the behavior of these methods must match. In the case of a file with the correct line separator(\n) it works properly.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              joehw Joe Wang
              Reporter:
              psemenov Pavel Semenov (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: