summaryrefslogtreecommitdiff
path: root/java/jdk16
diff options
context:
space:
mode:
authorGreg Lewis <glewis@FreeBSD.org>2011-02-09 17:13:40 +0000
committerGreg Lewis <glewis@FreeBSD.org>2011-02-09 17:13:40 +0000
commit4b975496460873b40e67a388e07d7e47db1ddbe4 (patch)
treeac697895e443fa94d469f154d52ba63026b272c2 /java/jdk16
parent- Update to 3.3.9.1 (diff)
. Fix infinite loop in parsing certain doubles. See CVE-2010-4476.
Diffstat (limited to 'java/jdk16')
-rw-r--r--java/jdk16/Makefile2
-rw-r--r--java/jdk16/files/patch-FloatingDecimal.java11
2 files changed, 12 insertions, 1 deletions
diff --git a/java/jdk16/Makefile b/java/jdk16/Makefile
index 10666e268dd8..e07cafb1deb8 100644
--- a/java/jdk16/Makefile
+++ b/java/jdk16/Makefile
@@ -7,7 +7,7 @@
PORTNAME= jdk
PORTVERSION= ${JDK_VERSION}.${JDK_UPDATE_VERSION}p${JDK_PATCHSET_VERSION}
-PORTREVISION= 20
+PORTREVISION= 21
CATEGORIES= java devel
MASTER_SITES= # http://download.java.net/jdk6/
# http://www.eyesbeyond.com/freebsddom/java/jdk16.html
diff --git a/java/jdk16/files/patch-FloatingDecimal.java b/java/jdk16/files/patch-FloatingDecimal.java
new file mode 100644
index 000000000000..6141b18cb7eb
--- /dev/null
+++ b/java/jdk16/files/patch-FloatingDecimal.java
@@ -0,0 +1,11 @@
+--- ../../j2se/src/share/classes/sun/misc/FloatingDecimal.java.orig 2011-02-08 21:47:56.000000000 -0800
++++ ../../j2se/src/share/classes/sun/misc/FloatingDecimal.java 2011-02-08 21:48:18.000000000 -0800
+@@ -1529,7 +1529,7 @@
+ if ( (cmpResult = bigB.cmp( bigD ) ) > 0 ){
+ overvalue = true; // our candidate is too big.
+ diff = bigB.sub( bigD );
+- if ( (bigIntNBits == 1) && (bigIntExp > -expBias) ){
++ if ( (bigIntNBits == 1) && (bigIntExp > -expBias+1) ){
+ // candidate is a normalized exact power of 2 and
+ // is too big. We will be subtracting.
+ // For our purposes, ulp is the ulp of the