null parameters for BigInteger constructors causes NullPointerException

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P5
    • 1.4.0
    • Affects Version/s: 1.2.0
    • Component/s: core-libs
    • beta2
    • x86
    • windows_nt
    • Verified



      Name: skT45625 Date: 11/09/2000


      Classic VM (build JDK-1.2.2-001, native threads, symcjit)

      When instantiating a java.math.BigInteger object using:

      BigInteger(int signum, byte[] magnitude)

      or

      BigInteger(String val, int radix)

      constructors and supplying null as a parameter for magnitude
      or val, the constructor throws a NullPointerException.
      I have not tried other constructors, but I suspect the behavior
      is the same.

      My suggestion would be to throw a NumberFormatException, since
      this is within the bounds of already defined behavior (according
      to the javadoc).
      (Review ID: 109239)
      ======================================================================

            Assignee:
            Scott Hommel (Inactive)
            Reporter:
            Suresh Kondamareddy (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: