Uploaded image for project: 'Commons Lang'
  1. Commons Lang
  2. LANG-638

NumberUtils createNumber throws a StringIndexOutOfBoundsException when argument containing "e" and "E" is passed in

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.5
    • Fix Version/s: 3.0
    • Component/s: lang.math.*
    • Labels:
      None

      Description

      NumberUtils createNumber throws a StringIndexOutOfBoundsException instead of NumberFormatException when a String containing both possible exponent indicators is passed in.
      One example of such a String is "1eE".

        Attachments

        1. NumberUtils.java.patch
          0.9 kB
          Ingo Heinrich
        2. NumberUtilsTest.java.patch
          0.5 kB
          Ingo Heinrich

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              iheinrich Ingo Heinrich
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: