summaryrefslogtreecommitdiff
blob: 5300fb19623599eb0b8180fb0b2be6118c2c2450 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
--- freenet-0.7.5_p1384/src/net/i2p/util/NativeBigInteger.java.orig	2011-07-29 16:48:36.000000000 +0200
+++ freenet-0.7.5_p1384/src/net/i2p/util/NativeBigInteger.java	2011-07-29 16:50:20.000000000 +0200
@@ -193,12 +193,6 @@
 	 */
 	public native static byte[] nativeModPow(byte base[], byte exponent[], byte modulus[]);
 
-	/**
-	 * Converts a BigInteger byte-array to a 'double'
-	 * @param ba Big endian twos complement representation of the BigInteger to convert to a double
-	 * @return The plain double-value represented by 'ba'
-	 */
-	public native static double nativeDoubleValue(byte ba[]);
 	private byte[] cachedBa = null;
 
         /**
@@ -286,11 +280,7 @@
 
 	@Override
 	public double doubleValue() {
-		// TODO Recent tests show that Java version is quicker. Maybe drop?
-		if(_nativeOk)
-			return nativeDoubleValue(toByteArray());
-		else
-			return super.doubleValue();
+		return super.doubleValue();
 	}
 
 	/**