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

NumberFormatException for messages CONFLICTING_XML_ELEMENT_MAPPING and NO_XML_EL

XMLWordPrintable

    • generic
    • generic

      FULL PRODUCT VERSION :
      java version "1.8.0_66"
      Java(TM) SE Runtime Environment (build 1.8.0_66-b17)
      Java HotSpot(TM) 64-Bit Server VM (build 25.66-b17, mixed mode)

      ADDITIONAL OS VERSION INFORMATION :
      Windows 7 64bits
      But should happen on every platforms.

      A DESCRIPTION OF THE PROBLEM :
      The messages CONFLICTING_XML_ELEMENT_MAPPING and NO_XML_EL contains strings reading " {'{0}'} ".

      In consequence, when the java.text.MessageFormat.format method is invoked with these keys, a NumberFormatException for input string " '{0}' " is raised as the first enclosing braces are considered as the argument placeholders, and the "'{0}'" part is considered as the argument index and parsed as an integer.


      REPRODUCIBILITY :
      This bug can be reproduced always.

      CUSTOMER SUBMITTED WORKAROUND :
      Manually update the resources.jar in the lib folder of the JRE to fix the culprit messages.

            psonal Pallavi Sonal (Inactive)
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: