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

java.math.BigInteger() hangs on solaris 2.6

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 1.4.0
    • 1.4.0
    • core-libs
    • beta
    • sparc
    • solaris_2.6



      Name: ksR10052 Date: 06/26/2000



      java.math.BigInteger(int bitLength, int certainty, Random rnd) hangs after several
      calls to it. See test example.

      Here is the example demonstrating the bug:
      ------------- test321.java -------------------------
      public class test321 {

          public static void main(String[] args) {
              java.util.Random rnd=new java.util.Random(1);
              BigInteger n;

              n = new BigInteger(2,0,rnd);
              n = new BigInteger(2,1,rnd);
              n = new BigInteger(2,2,rnd);
              n = new BigInteger(2,2,rnd);
              n = new BigInteger(2,2,rnd);
              n = new BigInteger(2,2,rnd);

              System.out.println("test complete");
              return;
          }

      }
      ========= Sample run (JDK1.4) ==========
      /set/java/jdk1.4/solaris/bin/java test321

      =========================== test hangs

      ========= Sample run (JDK1.3) ==========
      java test321
      test complete
      ========================================

      ======================================================================

            mmcclosksunw Michael Mccloskey (Inactive)
            skosunw Sko Sko (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: