/hg/icedtea6: 2012-01-12 Pavel Tisnovsky <ptisnovs at redhat.com>
ptisnovs at icedtea.classpath.org
ptisnovs at icedtea.classpath.org
Thu Jan 12 01:46:27 PST 2012
changeset 459e476245c6 in /hg/icedtea6
details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=459e476245c6
author: ptisnovs
date: Thu Jan 12 11:46:17 2012 +0100
2012-01-12 Pavel Tisnovsky <ptisnovs at redhat.com>
* Makefile.am: Add new patch.
* NEWS: Mention backport.
* patches/openjdk/6764553-IdResolver_is_not_thread_safe.patch:
Backport of 6764553:
com.sun.org.apache.xml.internal.security.utils.IdResolver is not
thread safe.
diffstat:
ChangeLog | 9 ++
Makefile.am | 3 +-
NEWS | 1 +
patches/openjdk/6764553-IdResolver_is_not_thread_safe.patch | 40 +++++++++++++
4 files changed, 52 insertions(+), 1 deletions(-)
diffs (85 lines):
diff -r 79014132e844 -r 459e476245c6 ChangeLog
--- a/ChangeLog Tue Jan 10 16:47:52 2012 +0000
+++ b/ChangeLog Thu Jan 12 11:46:17 2012 +0100
@@ -1,3 +1,12 @@
+2012-01-12 Pavel Tisnovsky <ptisnovs at redhat.com>
+
+ * Makefile.am: Add new patch.
+ * NEWS: Mention backport.
+ * patches/openjdk/6764553-IdResolver_is_not_thread_safe.patch:
+ Backport of 6764553:
+ com.sun.org.apache.xml.internal.security.utils.IdResolver is not
+ thread safe.
+
2012-01-10 Andrew John Hughes <ahughes at redhat.com>
* Makefile.am: Add new patch.
diff -r 79014132e844 -r 459e476245c6 Makefile.am
--- a/Makefile.am Tue Jan 10 16:47:52 2012 +0000
+++ b/Makefile.am Thu Jan 12 11:46:17 2012 +0100
@@ -404,7 +404,8 @@
patches/openjdk/6851973-kerberos.patch \
patches/openjdk/7091528-javadoc_class_files.patch \
patches/openjdk/7103725-ssl_beast_regression.patch \
- patches/openjdk/6706974-krb5_test_infrastructure.patch
+ patches/openjdk/6706974-krb5_test_infrastructure.patch \
+ patches/openjdk/6764553-IdResolver_is_not_thread_safe.patch
if WITH_RHINO
ICEDTEA_PATCHES += \
diff -r 79014132e844 -r 459e476245c6 NEWS
--- a/NEWS Tue Jan 10 16:47:52 2012 +0000
+++ b/NEWS Thu Jan 12 11:46:17 2012 +0100
@@ -14,6 +14,7 @@
* Backports
- 6706974: Add krb5 test infrastructure
+ - 6764553: com.sun.org.apache.xml.internal.security.utils.IdResolver is not thread safe
New in release 1.11 (2012-XX-XX):
diff -r 79014132e844 -r 459e476245c6 patches/openjdk/6764553-IdResolver_is_not_thread_safe.patch
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/openjdk/6764553-IdResolver_is_not_thread_safe.patch Thu Jan 12 11:46:17 2012 +0100
@@ -0,0 +1,41 @@
+# HG changeset patch
+# User mullan
+# Date 1225401848 14400
+# Node ID 4ff842aee1fdf3e8302c0a5f4dcd511cfc8ccb5a
+# Parent 58e52eb46bd33e155ed4cbeaee7ce077a0459932
+6764553: com.sun.org.apache.xml.internal.security.utils.IdResolver is not thread safe
+Reviewed-by: valeriep
+
+diff -r 58e52eb46bd3 -r 4ff842aee1fd src/share/classes/com/sun/org/apache/xml/internal/security/utils/IdResolver.java
+--- openjdk.orig/jdk/src/share/classes/com/sun/org/apache/xml/internal/security/utils/IdResolver.java Tue Oct 28 18:21:36 2008 +0100
++++ openjdk/jdk/src/share/classes/com/sun/org/apache/xml/internal/security/utils/IdResolver.java Thu Oct 30 17:24:08 2008 -0400
+@@ -73,10 +73,13 @@
+ */
+ public static void registerElementById(Element element, String idValue) {
+ Document doc = element.getOwnerDocument();
+- WeakHashMap elementMap = (WeakHashMap) docMap.get(doc);
+- if(elementMap == null) {
+- elementMap = new WeakHashMap();
+- docMap.put(doc, elementMap);
++ WeakHashMap elementMap;
++ synchronized (docMap) {
++ elementMap = (WeakHashMap) docMap.get(doc);
++ if (elementMap == null) {
++ elementMap = new WeakHashMap();
++ docMap.put(doc, elementMap);
++ }
+ }
+ elementMap.put(idValue, new WeakReference(element));
+ }
+@@ -158,7 +161,10 @@
+ private static Element getElementByIdType(Document doc, String id) {
+ if (true)
+ if (log.isLoggable(java.util.logging.Level.FINE)) log.log(java.util.logging.Level.FINE, "getElementByIdType() Search for ID " + id);
+- WeakHashMap elementMap = (WeakHashMap) docMap.get(doc);
++ WeakHashMap elementMap;
++ synchronized (docMap) {
++ elementMap = (WeakHashMap) docMap.get(doc);
++ }
+ if (elementMap != null) {
+ WeakReference weakReference = (WeakReference) elementMap.get(id);
+ if (weakReference != null)
More information about the distro-pkg-dev
mailing list