aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorglewis <glewis@FreeBSD.org>2004-12-17 15:02:51 +0800
committerglewis <glewis@FreeBSD.org>2004-12-17 15:02:51 +0800
commitf03de6b42bbb33e6d198e4e13986fcefe725dbe2 (patch)
tree1e889065ecc0c12967e85bfe79ee60e6a79eb3f6
parentb9d3df9033b05801bd61181aba1bdedfc83b47e5 (diff)
downloadfreebsd-ports-gnome-f03de6b42bbb33e6d198e4e13986fcefe725dbe2.tar.gz
freebsd-ports-gnome-f03de6b42bbb33e6d198e4e13986fcefe725dbe2.tar.zst
freebsd-ports-gnome-f03de6b42bbb33e6d198e4e13986fcefe725dbe2.zip
. Update to patchset 7.
. Fix a permissions problem with the plugins directory. Approved by: phantom (maintainer)
-rw-r--r--java/jdk14/Makefile6
-rw-r--r--java/jdk14/distinfo4
-rw-r--r--java/jdk14/files/patch-awt_Component.c13
-rw-r--r--java/jdk14/files/patch-awt_fontmanager_fontObject.cpp53
-rw-r--r--java/jdk14/files/patch-awt_fontmanager_t2kScalerContext.cpp21
-rw-r--r--java/jdk14/files/patch-deploy::Makefile46
-rw-r--r--java/jdk14/files/patch-font.properties.zh_TW.bsd302
-rw-r--r--java/jdk14/files/patch-hpi_monitor_md.c11
-rw-r--r--java/jdk14/files/patch-interpreter_bytecodes.hpp24
-rw-r--r--java/jdk14/files/patch-interpreter_shared.hpp38
-rw-r--r--java/jdk14/files/patch-io_io_util.h21
-rw-r--r--java/jdk14/files/patch-javascript_JSClassLoader.java243
-rw-r--r--java/jdk14/files/patch-javascript_JSInvoke.java26
-rw-r--r--java/jdk14/files/patch-javascript_ReflectUtil.java312
-rw-r--r--java/jdk14/files/patch-liveconnect_ReplaceMethod.java93
-rw-r--r--java/jdk14/files/patch-liveconnect_SecureInvocation.java351
-rw-r--r--java/jdk14/files/patch-native::util.c16
-rw-r--r--java/jdk14/files/patch-nspr_pth.h11
-rw-r--r--java/jdk14/files/patch-plugin_DispatchImpl.java331
-rw-r--r--java/jdk14/files/patch-plugin_FileList.gmk22
-rw-r--r--java/jdk14/files/patch-plugin_MethodDispatcher.java41
-rw-r--r--java/jdk14/files/patch-plugin_ns600_nscore.h13
-rw-r--r--java/jdk14/files/patch-plugin_ns610_nscore.h13
-rw-r--r--java/jdk14/files/patch-vm::os_bsd.hpp13
-rw-r--r--java/jdk14/pkg-plist2
-rw-r--r--java/jdk15/Makefile6
-rw-r--r--java/jdk15/distinfo4
-rw-r--r--java/jdk15/files/patch-awt_Component.c13
-rw-r--r--java/jdk15/files/patch-awt_fontmanager_fontObject.cpp53
-rw-r--r--java/jdk15/files/patch-awt_fontmanager_t2kScalerContext.cpp21
-rw-r--r--java/jdk15/files/patch-deploy::Makefile46
-rw-r--r--java/jdk15/files/patch-font.properties.zh_TW.bsd302
-rw-r--r--java/jdk15/files/patch-hpi_monitor_md.c11
-rw-r--r--java/jdk15/files/patch-interpreter_bytecodes.hpp24
-rw-r--r--java/jdk15/files/patch-interpreter_shared.hpp38
-rw-r--r--java/jdk15/files/patch-io_io_util.h21
-rw-r--r--java/jdk15/files/patch-javascript_JSClassLoader.java243
-rw-r--r--java/jdk15/files/patch-javascript_JSInvoke.java26
-rw-r--r--java/jdk15/files/patch-javascript_ReflectUtil.java312
-rw-r--r--java/jdk15/files/patch-liveconnect_ReplaceMethod.java93
-rw-r--r--java/jdk15/files/patch-liveconnect_SecureInvocation.java351
-rw-r--r--java/jdk15/files/patch-native::util.c16
-rw-r--r--java/jdk15/files/patch-nspr_pth.h11
-rw-r--r--java/jdk15/files/patch-plugin_DispatchImpl.java331
-rw-r--r--java/jdk15/files/patch-plugin_FileList.gmk22
-rw-r--r--java/jdk15/files/patch-plugin_MethodDispatcher.java41
-rw-r--r--java/jdk15/files/patch-plugin_ns600_nscore.h13
-rw-r--r--java/jdk15/files/patch-plugin_ns610_nscore.h13
-rw-r--r--java/jdk15/files/patch-vm::os_bsd.hpp13
-rw-r--r--java/jdk15/pkg-plist2
-rw-r--r--java/jdk16/Makefile6
-rw-r--r--java/jdk16/distinfo4
-rw-r--r--java/jdk16/files/patch-awt_Component.c13
-rw-r--r--java/jdk16/files/patch-awt_fontmanager_fontObject.cpp53
-rw-r--r--java/jdk16/files/patch-awt_fontmanager_t2kScalerContext.cpp21
-rw-r--r--java/jdk16/files/patch-deploy::Makefile46
-rw-r--r--java/jdk16/files/patch-font.properties.zh_TW.bsd302
-rw-r--r--java/jdk16/files/patch-hpi_monitor_md.c11
-rw-r--r--java/jdk16/files/patch-interpreter_bytecodes.hpp24
-rw-r--r--java/jdk16/files/patch-interpreter_shared.hpp38
-rw-r--r--java/jdk16/files/patch-io_io_util.h21
-rw-r--r--java/jdk16/files/patch-javascript_JSClassLoader.java243
-rw-r--r--java/jdk16/files/patch-javascript_JSInvoke.java26
-rw-r--r--java/jdk16/files/patch-javascript_ReflectUtil.java312
-rw-r--r--java/jdk16/files/patch-liveconnect_ReplaceMethod.java93
-rw-r--r--java/jdk16/files/patch-liveconnect_SecureInvocation.java351
-rw-r--r--java/jdk16/files/patch-native::util.c16
-rw-r--r--java/jdk16/files/patch-nspr_pth.h11
-rw-r--r--java/jdk16/files/patch-plugin_DispatchImpl.java331
-rw-r--r--java/jdk16/files/patch-plugin_FileList.gmk22
-rw-r--r--java/jdk16/files/patch-plugin_MethodDispatcher.java41
-rw-r--r--java/jdk16/files/patch-plugin_ns600_nscore.h13
-rw-r--r--java/jdk16/files/patch-plugin_ns610_nscore.h13
-rw-r--r--java/jdk16/files/patch-vm::os_bsd.hpp13
-rw-r--r--java/jdk16/pkg-plist2
75 files changed, 24 insertions, 6054 deletions
diff --git a/java/jdk14/Makefile b/java/jdk14/Makefile
index 169a67f7b96d..31744bfcb4b1 100644
--- a/java/jdk14/Makefile
+++ b/java/jdk14/Makefile
@@ -7,7 +7,6 @@
PORTNAME= jdk
PORTVERSION= ${JDK_VERSION}p${JDK_PATCHSET_VERSION}
-PORTREVISION= 7
CATEGORIES= java devel
MASTER_SITES= # http://www.sun.com/software/java2/download.html
# http://www.eyesbeyond.com/freebsddom/java/jdk14.html
@@ -32,7 +31,7 @@ RUN_DEPENDS+= ${X11BASE}/lib/X11/fonts/URW/fonts.dir:${PORTSDIR}/x11-fonts/urwfo
WRKSRC= ${WRKDIR}/control/make
JDK_VERSION= 1.4.2
-JDK_PATCHSET_VERSION= 6
+JDK_PATCHSET_VERSION= 7
LATEST_LINK= jdk14
SUN_LINUX_JDK_VERSION= 1.4.2
@@ -315,6 +314,9 @@ do-install:
.endif
post-install:
+.if !defined(MINIMAL)
+ ${FIND} "${PREFIX}/jdk${JDK_VERSION}/jre/plugin" -type d | ${XARGS} ${CHMOD} a+rx
+.endif
@${LOCALBASE}/bin/registervm "${PREFIX}/jdk${JDK_VERSION}/bin/java # FREEBSD-JDK${JDK_VERSION}"
@${SED} -e "s:%%JRE_HOME%%:${PREFIX}/jdk${JDK_VERSION}/jre:g" \
< ${FILESDIR}/pkg-install.in > ${PKGINSTALL}
diff --git a/java/jdk14/distinfo b/java/jdk14/distinfo
index 9fb0a0721197..fb62f1cbad29 100644
--- a/java/jdk14/distinfo
+++ b/java/jdk14/distinfo
@@ -2,5 +2,5 @@ MD5 (j2sdk-1_4_2-src-scsl.zip) = 387ae674dcd686f3a7a477c191aa8b65
SIZE (j2sdk-1_4_2-src-scsl.zip) = 49269919
MD5 (j2sdk-1_4_2-bin-scsl.zip) = 24877ff50ae66744090c3723968bb7dc
SIZE (j2sdk-1_4_2-bin-scsl.zip) = 2513462
-MD5 (bsd-jdk14-patches-6.tar.gz) = fe01a66ce4e8425f169c1b4a88d08f87
-SIZE (bsd-jdk14-patches-6.tar.gz) = 1068798
+MD5 (bsd-jdk14-patches-7.tar.gz) = fe76afc2dd8651350a2f0e221d928fa5
+SIZE (bsd-jdk14-patches-7.tar.gz) = 1137785
diff --git a/java/jdk14/files/patch-awt_Component.c b/java/jdk14/files/patch-awt_Component.c
deleted file mode 100644
index db768c611349..000000000000
--- a/java/jdk14/files/patch-awt_Component.c
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/solaris/native/sun/awt/awt_Component.c.orig 27 Oct 2003 12:16:41 -0000 1.4
-+++ ../../j2se/src/solaris/native/sun/awt/awt_Component.c 1 Mar 2004 21:36:45 -0000 1.5
-@@ -1179,7 +1179,7 @@
- }
- XtVaSetValues(to, XmNtraversalOn, True, NULL);
- }
-- } else if (from != NULL) {
-+ } else if (from != NULL && to != NULL) {
- // disable the tree starting from uncommon part to 'from'
- if (parents_from[index] == parents_to[index]) {
- if (index == count_from - 1) {
diff --git a/java/jdk14/files/patch-awt_fontmanager_fontObject.cpp b/java/jdk14/files/patch-awt_fontmanager_fontObject.cpp
deleted file mode 100644
index 3efc10e85b68..000000000000
--- a/java/jdk14/files/patch-awt_fontmanager_fontObject.cpp
+++ /dev/null
@@ -1,53 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/fontObject.cpp.orig Wed Jul 7 09:33:52 2004
-+++ ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/fontObject.cpp Wed Jul 7 13:26:03 2004
-@@ -416,7 +416,11 @@
- fUseCount += 1;
-
- if (length > 0 && fFileSize > 0) {
-- assert(offset < fFileSize);
-+ if (offset >= fFileSize) {
-+ fUseCount--;
-+ return NULL;
-+ }
-+
- if ((offset + length) > fFileSize)
- length = fFileSize - offset;
-
-@@ -431,13 +435,14 @@
- "fileFontObject::ReadChunk(UInt32,UInt32,void*)\n"
- );
- #endif
-+ fUseCount--;
- return NULL;
- }
-
- off_t err = lseek(fFile, offset, SEEK_SET);
- #ifdef DEBUG
- if (err == (off_t)-1) {
-- fprintf(stderr, "seek(%d) returned %d\n", offset, (int) err);
-+ fprintf(stderr, "seek(%ld) returned %d\n", offset, (int) err);
- }
- #endif
-
-@@ -448,7 +453,7 @@
- int tellvalue = lseek(fFile, 0, SEEK_END);
- #ifdef DEBUG
- fprintf(stderr,
-- "<%s> of %d, ln %d, rd %d, sz %d, tell %d, err %d\n",
-+ "<%s> of %ld, ln %ld, rd %d, sz %ld, tell %d, err %d\n",
- (char *)fFileName, offset, length, (int)bytesRead,
- fFileSize, tellvalue, (int) err);
- #endif
-@@ -1457,7 +1462,9 @@
- return false;
- }
-
-- this->ReadChunk(sizeof theHeader, fFontCount * sizeof *offsets, offsets);
-+ if (this->ReadChunk(sizeof theHeader, fFontCount * sizeof *offsets, offsets) == NULL) {
-+ return false;
-+ }
- for (int i=0; i<fFontCount; i++) {
- offsets[i] = GET32(offsets[i]);
- }
diff --git a/java/jdk14/files/patch-awt_fontmanager_t2kScalerContext.cpp b/java/jdk14/files/patch-awt_fontmanager_t2kScalerContext.cpp
deleted file mode 100644
index 7f39f7cceabb..000000000000
--- a/java/jdk14/files/patch-awt_fontmanager_t2kScalerContext.cpp
+++ /dev/null
@@ -1,21 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/t2kScalerContext.cpp.orig Fri Jul 30 18:00:09 2004
-+++ ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/t2kScalerContext.cpp Fri Jul 30 22:11:36 2004
-@@ -937,14 +937,14 @@
- CMAPMapper::CharsToGlyphs(
- int count, const Unicode16 unicodes[], UInt32 glyphs[]) const
- {
-- ConvertUnicodeToGlyphs(*font, (unsigned char *)cmap, count, unicodes, glyphs);
-+ ConvertUnicodeToGlyphs(*font, (byte*&)cmap, count, unicodes, glyphs);
- }
-
- void
- CMAPMapper::CharsToGlyphs(
- int count, const Unicode32 unicodes[], UInt32 glyphs[]) const
- {
-- ConvertUnicodeToGlyphs(*font, (unsigned char *)cmap, count, unicodes, glyphs);
-+ ConvertUnicodeToGlyphs(*font, (byte*&)cmap, count, unicodes, glyphs);
- }
-
- //////////////////////////////////////////////////////////////////////////////
diff --git a/java/jdk14/files/patch-deploy::Makefile b/java/jdk14/files/patch-deploy::Makefile
deleted file mode 100644
index a34bfa0c9d71..000000000000
--- a/java/jdk14/files/patch-deploy::Makefile
+++ /dev/null
@@ -1,46 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/make/Makefile.orig Tue Jan 27 18:54:56 2004
-+++ ../../deploy/make/Makefile Tue Jan 27 18:58:08 2004
-@@ -24,17 +24,29 @@
- DEPLOY_TOPDIR=..
- include $(BUILDDIR)/common/Defs.gmk
-
-+ifdef NO_PLUGIN
-+BUILD_PLUGIN= false
-+else
-+BUILD_PLUGIN= true
-+endif
-+
-+ifdef NO_JAVAWS
-+BUILD_JAVAWS= false
-+else
-+BUILD_JAVAWS= true
-+endif
-+
- all::
- @$(ECHO) "$(PLATFORM) $(ARCH) $(RELEASE) deploy build started: $(shell $(DATE) '+%y-%m-%d %H:%M')"
-
--BUILD_PLUGIN = true
--
- #
- # Core.
- #
- JAVAWS_SUBDIR = javaws
- PLUGIN_SUBDIR = plugin
-+ifeq ($(BUILD_JAVAWS), true)
- SUBDIRS = $(JAVAWS_SUBDIR)
-+endif
- ifeq ($(BUILD_PLUGIN), true)
- SUBDIR += $(PLUGIN_SUBDIR)
- endif
-@@ -47,7 +59,9 @@
- done
-
- javaws-all: sanity-javaws
-+ ifeq ($(BUILD_JAVAWS), true)
- $(CD) $(BUILDDIR)/javaws ; $(MAKE) installer-int dev-all doc aubundle
-+ endif
-
- plugin-all: sanity-plugin
- ifeq ($(BUILD_PLUGIN), true)
diff --git a/java/jdk14/files/patch-font.properties.zh_TW.bsd b/java/jdk14/files/patch-font.properties.zh_TW.bsd
deleted file mode 100644
index a142781b2ee2..000000000000
--- a/java/jdk14/files/patch-font.properties.zh_TW.bsd
+++ /dev/null
@@ -1,302 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/solaris/classes/sun/awt/motif/font.properties.zh_TW.bsd.orig 16 Aug 2002 06:04:59 -0000 1.1
-+++ ../../j2se/src/solaris/classes/sun/awt/motif/font.properties.zh_TW.bsd 1 Mar 2004 21:40:08 -0000 1.2
-@@ -1,235 +1,178 @@
-+# %W% %E%
- #
--# @(#)font.properties.zh 1.0 00/06/20
--#
--# Copyright 2000 by Sun Microsystems, Inc.,
--# 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
--# All rights reserved.
--#
--# This software is the confidential and proprietary information
--# of Sun Microsystems, Inc. ("Confidential Information"). You
--# shall not disclose such Confidential Information and shall use
--# it only in accordance with the terms of the license agreement
--# you entered into with Sun.
--#
--
--#
--# AWT Font default Properties for Simplified Chinese TurboLinux 6.0 and higher
-+# Copyright 2002 Sun Microsystems, Inc. All rights reserved.
- #
-
--# Serif font definition
-+# Component Font Mappings For RedhatLinux 8.0/zh_TW
- #
- serif.0=-b&h-lucidabright-medium-r-normal--*-%d-*-*-p-*-iso8859-1
--serif.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.italic.0=-b&h-lucidabright-medium-i-normal--*-%d-*-*-p-*-iso8859-1
--serif.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.bold.0=-b&h-lucidabright-demibold-r-normal--*-%d-*-*-p-*-iso8859-1
--serif.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.bolditalic.0=-b&h-lucidabright-demibold-i-normal--*-%d-*-*-p-*-iso8859-1
--serif.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# SansSerif font definition
--#
- sansserif.0=-b&h-lucidasans-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.italic.0=-b&h-lucidasans-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.bold.0=-b&h-lucidasans-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.bolditalic.0=-b&h-lucidasans-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Monospaced font definition
--#
- monospaced.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--monospaced.italic.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.italic.0=-b&h-lucidatypewriter-medium-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+monospaced.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- monospaced.bold.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--monospaced.bolditalic.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.bolditalic.0=-b&h-lucidatypewriter-bold-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+monospaced.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Dialog font definition
--#
- dialog.0=-b&h-lucidasans-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.italic.0=-b&h-lucidasans-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.bold.0=-b&h-lucidasans-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.bolditalic.0=-b&h-lucidasans-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# DialogInput font definition
--#
- dialoginput.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--dialoginput.italic.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.italic.0=-b&h-lucidatypewriter-medium-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+dialoginput.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialoginput.bold.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
--
--dialoginput.bolditalic.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
-+dialoginput.bolditalic.0=-b&h-lucidatypewriter-bold-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+dialoginput.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Default font definition
-+# Missing Glyph Character
- #
- default.char=274f
-
--# name aliases
--#
--# alias.timesroman=serif
--# alias.helvetica=sansserif
--# alias.courier=monospaced
--
--# for backward compatibility
--#
--#zapfdingbats.0=-monotype-monotype sorts-regular-r---*-%d-*-*-p-*-adobe-dingbats
--
--# Static FontCharset info.
--#
--# This information is used by the font which is not indexed by Unicode.
--# Such fonts can use their own subclass of FontCharset.
--#
--# This information can be overriden by describing more specific style.
--# For example
--#
--# fontcharset.serif.plain.3=SpecialSymbols
--# means serif.plain.3 font's index can be retrieved with the convert() method
--# of instance of SpecialSymbols and what kind of characters serif.plain.3 font
--# has can be judged with the isCovered() method of instance of SpecialSymbols.
-+# Component Font Character Encodings
- #
- fontcharset.serif.0=sun.io.CharToByteISO8859_1
--fontcharset.serif.1=sun.io.CharToByteMS950
-+fontcharset.serif.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.sansserif.0=sun.io.CharToByteISO8859_1
--fontcharset.sansserif.1=sun.io.CharToByteMS950
-+fontcharset.sansserif.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.monospaced.0=sun.io.CharToByteISO8859_1
--fontcharset.monospaced.1=sun.io.CharToByteMS950
-+fontcharset.monospaced.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.dialog.0=sun.io.CharToByteISO8859_1
--fontcharset.dialog.1=sun.io.CharToByteMS950
-+fontcharset.dialog.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.dialoginput.0=sun.io.CharToByteISO8859_1
--fontcharset.dialoginput.1=sun.io.CharToByteMS950
-+fontcharset.dialoginput.1=sun.io.CharToByteUnicodeBigUnmarked
-
--# exclusion info.
--#
--# This information describe exclusion ranges for each fonts.
--#
--# 'exclusion.serif.plain.0' overrides 'exclusion.serif.0', and
--# 'exclusion.serif.0' overrides exclusion.0, and so on.
-+# Exclusion Ranges
- #
-
--# XFontSet string
--# X11 only properties
-+# XFontSet Information
- #
- fontset.serif.plain=\
- -b&h-lucidabright-medium-r-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.italic=\
- -b&h-lucidabright-medium-i-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.bold=\
- -b&h-lucidabright-demibold-r-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.bolditalic=\
- -b&h-lucidabright-demibold-i-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
--
--# SansSerif font definition
--#
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.plain=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.italic=\
- -b&h-lucida-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.bold=\
---b&h-lucida-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.bolditalic=\
---b&h-lucida-bold-i-normal-snas-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# Monospaced font definition
--#
- fontset.monospaced.plain=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.italic=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.bold=\
---b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-,1\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.bolditalic=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# Dialog font definition
--#
- fontset.dialog.italic=\
- -b&h-lucida-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.bold=\
- -b&h-lucida-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.bolditalic=\
- -b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.plain=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# DialogInput font definition
--#
- fontset.dialoginput.italic=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.bold=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.bolditalic=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.plain=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--#
- fontset.default=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-+
-+filename.-arphic_technology_co.-ar_pl_mingti2l_big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1=/usr/local/share/fonts/TrueType/bsmi00lp.ttf
diff --git a/java/jdk14/files/patch-hpi_monitor_md.c b/java/jdk14/files/patch-hpi_monitor_md.c
deleted file mode 100644
index ca874dd9cd35..000000000000
--- a/java/jdk14/files/patch-hpi_monitor_md.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- ../../j2se/src/solaris/hpi/native_threads/src/monitor_md.c 22 Oct 2003 23:03:43 -0000 1.1.1.2
-+++ ../../j2se/src/solaris/hpi/native_threads/src/monitor_md.c 21 Oct 2004 05:42:52 -0000
-@@ -129,7 +129,7 @@
- mid->monitor_owner = self;
- mid->entry_count = 1;
- return SYS_OK;
-- } else if (err == EBUSY) { /* it's already locked */
-+ } else if (err == EBUSY || err == EDEADLK) { /* it's already locked */
- if (mid->monitor_owner == self) {
- mid->entry_count++;
- return SYS_OK;
diff --git a/java/jdk14/files/patch-interpreter_bytecodes.hpp b/java/jdk14/files/patch-interpreter_bytecodes.hpp
deleted file mode 100644
index 112722cac07e..000000000000
--- a/java/jdk14/files/patch-interpreter_bytecodes.hpp
+++ /dev/null
@@ -1,24 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/share/vm/interpreter/bytecodes.hpp 22 Oct 2003 23:05:03 -0000 1.1.1.3
-+++ ../../hotspot/src/share/vm/interpreter/bytecodes.hpp 12 Oct 2004 05:27:27 -0000
-@@ -6,6 +6,9 @@
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-+
-+#include <limits.h>
-+
- // Bytecodes specifies all bytecodes used in the VM and
- // provides utility functions to get bytecode attributes.
-
-@@ -236,7 +239,8 @@
- // Platform specific JVM bytecodes
- #include "incls/_bytecodes_pd.hpp.incl"
-
-- number_of_codes
-+ number_of_codes,
-+ WIDTH_HINT = INT_MAX
- };
-
- private:
diff --git a/java/jdk14/files/patch-interpreter_shared.hpp b/java/jdk14/files/patch-interpreter_shared.hpp
deleted file mode 100644
index 25feb1ff8da9..000000000000
--- a/java/jdk14/files/patch-interpreter_shared.hpp
+++ /dev/null
@@ -1,38 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/share/vm/interpreter/shared.hpp 22 Oct 2003 23:05:05 -0000 1.1.1.2
-+++ ../../hotspot/src/share/vm/interpreter/shared.hpp 10 Oct 2004 05:03:55 -0000
-@@ -41,19 +41,17 @@
- // to control the C++ namespace.
- class OptoReg VALUE_OBJ_CLASS_SPEC {
- public:
-- enum Name {
-- // Chunk 0
-+ typedef int Name;
- #ifdef COMPILER2
-- Physical = AdlcVMDeps::Physical, // Start of physical regs
-+ static const Name Physical = AdlcVMDeps::Physical; // Start of physical regs
- #endif
- // A few oddballs at the edge of the world
-- Special = -2, // All special (not allocated) values
-- Bad = -1 // Not a register
-- };
-+ static const Name Special = -2; // All special (not allocated) values
-+ static const Name Bad = -1; // Not a register
-
- // Increment a register number. As in:
- // "for ( OptoReg::Name i; i=Control; i = add(i,1) ) ..."
-- static Name add( Name x, int y ) { return Name(x+y); }
-+ static Name add( Name x, int y ) { return (x+y); }
-
- // (We would like to have an operator+ for RegName, but it is not
- // a class, so this would be illegal in C++.)
-@@ -70,7 +68,7 @@
- // when we do not yet know how big the frame will be.
- class VMReg VALUE_OBJ_CLASS_SPEC {
- public:
-- enum Name { };
-+ typedef int Name;
- };
-
-
diff --git a/java/jdk14/files/patch-io_io_util.h b/java/jdk14/files/patch-io_io_util.h
deleted file mode 100644
index 80f00417aa2b..000000000000
--- a/java/jdk14/files/patch-io_io_util.h
+++ /dev/null
@@ -1,21 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/java/io/io_util.h.orig Wed Jul 21 08:32:49 2004
-+++ ../../j2se/src/share/native/java/io/io_util.h Wed Jul 21 08:37:54 2004
-@@ -10,7 +10,15 @@
-
- extern jfieldID IO_fd_fdID;
-
--#if !defined(O_DSYNC) || !defined(O_SYNC)
-+#ifdef _BSD_SOURCE
-+#include <fcntl.h>
-+#ifndef O_SYNC
-+#define O_SYNC O_FSYNC
-+#endif
-+#ifndef O_DSYNC
-+#define O_DSYNC O_FSYNC
-+#endif
-+#elif !defined(O_DSYNC) || !defined(O_SYNC)
- #define O_SYNC (0x0800)
- #define O_DSYNC (0x2000)
- #endif
diff --git a/java/jdk14/files/patch-javascript_JSClassLoader.java b/java/jdk14/files/patch-javascript_JSClassLoader.java
deleted file mode 100644
index 1e3a9ad3080b..000000000000
--- a/java/jdk14/files/patch-javascript_JSClassLoader.java
+++ /dev/null
@@ -1,243 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSClassLoader.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSClassLoader.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,238 @@
-+/*
-+ * @(#)JSClassLoader.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+
-+package sun.plugin.javascript;
-+
-+import java.security.AllPermission;
-+import java.security.AccessController;
-+import java.security.PermissionCollection;
-+import java.security.SecureClassLoader;
-+import java.security.PrivilegedExceptionAction;
-+import java.security.CodeSource;
-+import java.io.InputStream;
-+import java.io.BufferedInputStream;
-+import java.io.IOException;
-+import java.net.URL;
-+import java.net.URLConnection;
-+import java.net.HttpURLConnection;
-+import java.lang.reflect.Method;
-+import java.lang.reflect.InvocationTargetException;
-+import java.lang.reflect.AccessibleObject;
-+import sun.net.www.ParseUtil;
-+import sun.security.util.SecurityConstants;
-+
-+/*
-+ * Create a trampoline class for JavaScript to Java
-+ * method invocations.
-+ *
-+ */
-+public final class JSClassLoader extends SecureClassLoader {
-+ private static String JS_PROXY_PKG = "sun.plugin.javascript.invoke.";
-+ private static String TRAMPOLINE = JS_PROXY_PKG + "JSInvoke";
-+ private static Method bounce;
-+
-+ /*
-+ * Bounce through the trampoline.
-+ */
-+ public static Object invoke(Method m, Object obj, Object[] params)
-+ throws Exception {
-+ try {
-+ return bounce().invoke(null, new Object[] {m, obj, params});
-+ } catch (InvocationTargetException ie) {
-+ Throwable t = ie.getCause();
-+
-+ if (t instanceof InvocationTargetException) {
-+ throw (InvocationTargetException)t;
-+ } else {
-+ throw ie;
-+ }
-+ }
-+ }
-+
-+ /**
-+ * Check the package access permission by giving a class
-+ *
-+ * @param clazz: The Class object trying to get access to
-+ *
-+ */
-+ public static void checkPackageAccess(Class clazz) {
-+ String clsname = clazz.getName();
-+ int index = clsname.lastIndexOf(".");
-+ if (index != -1) {
-+ String pkgname = clsname.substring(0, index);
-+ SecurityManager s = System.getSecurityManager();
-+ if (s != null) {
-+ s.checkPackageAccess(pkgname);
-+ }
-+ }
-+ }
-+
-+ public static boolean isPackageAccessible(Class clazz) {
-+ try {
-+ checkPackageAccess(clazz);
-+ } catch (SecurityException e) {
-+ return false;
-+ }
-+ return true;
-+ }
-+
-+
-+ private synchronized static Method bounce() throws Exception {
-+ if (bounce == null) {
-+ bounce = (Method) AccessController.doPrivileged(new PrivilegedExceptionAction() {
-+ public Object run() throws Exception {
-+ Class[] types;
-+ Class t = getTrampoline();
-+ Method b;
-+
-+ types = new Class[] {Method.class, Object.class, Object[].class};
-+ b = t.getDeclaredMethod("invoke", types);
-+ ((AccessibleObject)b).setAccessible(true);
-+ return b;
-+ }
-+ });
-+ }
-+ return bounce;
-+ }
-+
-+ private static Class getTrampoline() {
-+ try {
-+ return Class.forName(TRAMPOLINE, true, new JSClassLoader());
-+ } catch (ClassNotFoundException e) {
-+ }
-+ return null;
-+ }
-+
-+
-+ protected synchronized Class loadClass(String name, boolean resolve)
-+ throws ClassNotFoundException
-+ {
-+ SecurityManager s = System.getSecurityManager();
-+ if (s != null) {
-+ String cname = name.replace('/', '.');
-+ if (cname.startsWith("[")) {
-+ int b = cname.lastIndexOf('[') + 2;
-+ if (b > 1 && b < cname.length()) {
-+ cname = cname.substring(b);
-+ }
-+ }
-+ int i = cname.lastIndexOf('.');
-+ if (i != -1) {
-+ s.checkPackageAccess(cname.substring(0, i));
-+ }
-+ }
-+ // First, check if the class has already been loaded
-+ Class c = findLoadedClass(name);
-+ if (c == null) {
-+ try {
-+ c = findClass(name);
-+ } catch (ClassNotFoundException e) {
-+ // Fall through ...
-+ }
-+ if (c == null) {
-+ c = getParent().loadClass(name);
-+ }
-+ }
-+ if (resolve) {
-+ resolveClass(c);
-+ }
-+ return c;
-+ }
-+
-+
-+ protected Class findClass(final String name)
-+ throws ClassNotFoundException
-+ {
-+ if (!name.startsWith(JS_PROXY_PKG)) {
-+ throw new ClassNotFoundException(name);
-+ }
-+ String path = name.replace('.', '/').concat(".class");
-+ URL res = getResource(path);
-+ if (res != null) {
-+ try {
-+ return defineClass(name, res);
-+ } catch (IOException e) {
-+ throw new ClassNotFoundException(name, e);
-+ }
-+ } else {
-+ throw new ClassNotFoundException(name);
-+ }
-+ }
-+
-+
-+ /*
-+ * Define the JavaScript proxy classes
-+ */
-+ private Class defineClass(String name, URL url) throws IOException {
-+ byte[] b = getBytes(url);
-+ CodeSource cs = new CodeSource(null, (java.security.cert.Certificate[])null);
-+ if (!name.equals(TRAMPOLINE)) {
-+ throw new IOException("JSClassLoader: bad name " + name);
-+ }
-+ return defineClass(name, b, 0, b.length, cs);
-+ }
-+
-+
-+ /*
-+ * Returns the contents of the specified URL as an array of bytes.
-+ */
-+ private static byte[] getBytes(URL url) throws IOException {
-+ URLConnection uc = url.openConnection();
-+ if (uc instanceof java.net.HttpURLConnection) {
-+ java.net.HttpURLConnection huc = (java.net.HttpURLConnection) uc;
-+ int code = huc.getResponseCode();
-+ if (code >= java.net.HttpURLConnection.HTTP_BAD_REQUEST) {
-+ throw new IOException("open HTTP connection failed.");
-+ }
-+ }
-+ int len = uc.getContentLength();
-+ InputStream in = new BufferedInputStream(uc.getInputStream());
-+
-+ byte[] b;
-+ try {
-+ if (len != -1) {
-+ // Read exactly len bytes from the input stream
-+ b = new byte[len];
-+ while (len > 0) {
-+ int n = in.read(b, b.length - len, len);
-+ if (n == -1) {
-+ throw new IOException("unexpected EOF");
-+ }
-+ len -= n;
-+ }
-+ } else {
-+ b = new byte[8192];
-+ int total = 0;
-+ while ((len = in.read(b, total, b.length - total)) != -1) {
-+ total += len;
-+ if (total >= b.length) {
-+ byte[] tmp = new byte[total * 2];
-+ System.arraycopy(b, 0, tmp, 0, total);
-+ b = tmp;
-+ }
-+ }
-+ // Trim array to correct size, if necessary
-+ if (total != b.length) {
-+ byte[] tmp = new byte[total];
-+ System.arraycopy(b, 0, tmp, 0, total);
-+ b = tmp;
-+ }
-+ }
-+ } finally {
-+ in.close();
-+ }
-+ return b;
-+ }
-+
-+
-+ protected PermissionCollection getPermissions(CodeSource codesource)
-+ {
-+ PermissionCollection perms = super.getPermissions(codesource);
-+ perms.add(new AllPermission());
-+ return perms;
-+ }
-+}
diff --git a/java/jdk14/files/patch-javascript_JSInvoke.java b/java/jdk14/files/patch-javascript_JSInvoke.java
deleted file mode 100644
index fc692b9cb9c1..000000000000
--- a/java/jdk14/files/patch-javascript_JSInvoke.java
+++ /dev/null
@@ -1,26 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSInvoke.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSInvoke.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,21 @@
-+/*
-+ * @(#)JSInvoke.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+
-+package sun.plugin.javascript.invoke;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.InvocationTargetException;
-+
-+/*
-+ * JavaScript to Java invocation trampoline class.
-+ */
-+class JSInvoke {
-+ private static Object invoke(Method m, Object obj, Object[] params)
-+ throws InvocationTargetException, IllegalAccessException {
-+ return m.invoke(obj, params);
-+ }
-+}
diff --git a/java/jdk14/files/patch-javascript_ReflectUtil.java b/java/jdk14/files/patch-javascript_ReflectUtil.java
deleted file mode 100644
index 827bd0c666ce..000000000000
--- a/java/jdk14/files/patch-javascript_ReflectUtil.java
+++ /dev/null
@@ -1,312 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/ReflectUtil.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/ReflectUtil.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,307 @@
-+/*
-+ * @(#)ReflectUtil.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+package sun.plugin.javascript;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Field;
-+import java.lang.reflect.Modifier;
-+import java.lang.reflect.InvocationTargetException;
-+import java.util.HashMap;
-+import java.util.ArrayList;
-+import java.util.List;
-+import java.util.Map;
-+import java.util.Iterator;
-+import sun.plugin.javascript.JSClassLoader;
-+
-+public class ReflectUtil {
-+ /*
-+ * Discover the public methods on public classes
-+ * and interfaces accessible to the calling
-+ * JavaScript code.
-+ */
-+ public static Method[] getJScriptMethods(Class cls) {
-+ List m = new ArrayList(); /* the valid methods we find */
-+
-+ /*
-+ * Temporary map of method signatures when we decide
-+ * that a simple call to target.getMethods() returns
-+ * inaccessible methods and we must search for alternative
-+ * supermethods that might be accessible. We can toss
-+ * this when we're done searching.
-+ */
-+ Map sigs = new HashMap();
-+
-+ while (cls != null) {
-+ boolean done = getPublicMethods(cls, m, sigs);
-+ if (done) {
-+ break;
-+ }
-+ getJScriptInterfaceMethods(cls, m, sigs);
-+ cls = cls.getSuperclass();
-+ }
-+ return (Method[]) m.toArray(new Method[m.size()]);
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ private static void getJScriptInterfaceMethods(Class cls, List m, Map sigs) {
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length; i++) {
-+ Class intf = intfs[i];
-+ boolean done = getPublicMethods(intf, m, sigs);
-+ if (!done) {
-+ getJScriptInterfaceMethods(intf, m, sigs);
-+ }
-+ }
-+ }
-+
-+ /*
-+ *
-+ * Process the methods in this class or interface
-+ */
-+ private static boolean getPublicMethods(Class cls, List m, Map sigs) {
-+ Method[] methods = null;
-+ try {
-+
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's methods. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return false;
-+ }
-+
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return false;
-+ }
-+
-+ methods = cls.getMethods();
-+ } catch (SecurityException se) {
-+ return false;
-+ }
-+
-+ /*
-+ * Check for inherited methods with non-public
-+ * declaring classes. They might override and hide
-+ * methods from their superclasses or
-+ * superinterfaces.
-+ */
-+ boolean done = true;
-+ for (int i=0; i < methods.length; i++) {
-+ Class dc = methods[i].getDeclaringClass();
-+ if (!Modifier.isPublic(dc.getModifiers())) {
-+ done = false;
-+ break;
-+ }
-+ }
-+
-+ /*
-+ * Belatedly initialize the signature map if
-+ * this is not the first time here.
-+ */
-+ if (sigs.isEmpty() && !m.isEmpty()) {
-+ initSignatureMap(m, sigs);
-+ }
-+
-+ if (done) {
-+ /*
-+ * We're done. Spray all the methods into
-+ * the list and then we're out of here.
-+ */
-+ for (int i=0; i < methods.length; i++) {
-+ addMethod(m, sigs, methods[i]);
-+ }
-+ } else {
-+ /*
-+ * Simulate cls.getDeclaredMethods() by
-+ * stripping away inherited methods.
-+ */
-+ for (int i=0; i < methods.length; i++) {
-+ Class dc = methods[i].getDeclaringClass();
-+ if (cls.equals(dc)) {
-+ addMethod(m, sigs, methods[i]);
-+ }
-+ }
-+ }
-+ return done;
-+ }
-+
-+ private static void initSignatureMap(List m, Map sigs) {
-+ Iterator i = m.iterator();
-+ while (i.hasNext()) {
-+ Method entry = (Method) i.next();
-+ sigs.put(getSignature(entry), entry);
-+ }
-+ }
-+
-+ private static void addMethod(List m, Map sigs, Method method) {
-+ /*
-+ * Avoid work. We ignore the signature matching
-+ * until the map is initialized in initSignatureMap.
-+ * This has the effect of avoiding the signature
-+ * work for the first call of getPublicMethods().
-+ */
-+ if (sigs.isEmpty()) {
-+ m.add(method);
-+ return;
-+ }
-+
-+ /*
-+ * Avoid adding duplicate accessible methods on
-+ * the list.
-+ */
-+ String signature = getSignature(method);
-+ if (!sigs.containsKey(signature)) {
-+ m.add(method);
-+ sigs.put(signature, method);
-+ }
-+ }
-+
-+ /*
-+ * Return a canonical method signature for the method.
-+ * We care only about the simple method name and the
-+ * the number, type and order of the parameters.
-+ * Exception declarations are not part of a method
-+ * signature nor is the return type.
-+ */
-+ private static String getSignature(Method method) {
-+ StringBuffer sb = new StringBuffer();
-+
-+ sb.append(method.getName());
-+ Class[] params = method.getParameterTypes();
-+ sb.append('(');
-+ if (params.length > 0) {
-+ sb.append(params[0].getName());
-+ }
-+ for (int i=1; i < params.length; i++) {
-+ sb.append(',');
-+ sb.append(params[i].getName());
-+ }
-+ sb.append(')');
-+
-+ return sb.toString();
-+ }
-+
-+ /*
-+ * Discover the public fields on public classes
-+ * and interfaces accessible to the calling
-+ * JavaScript code.
-+ */
-+ public static Field[] getJScriptFields(Class cls) {
-+ List m = new ArrayList(); /* the valid fields we find */
-+
-+ /*
-+ * Temporary map of field name when we decide
-+ * that a simple call to target.getFields() returns
-+ * inaccessible fields and we must search for alternative
-+ * supermethods that might be accessible. We can toss
-+ * this when we're done searching.
-+ */
-+ Map names = new HashMap();
-+
-+ while (cls != null) {
-+ boolean done = getPublicFields(cls, m, names);
-+ if (done) {
-+ break;
-+ }
-+ getJScriptInterfaceFields(cls, m, names);
-+ cls = cls.getSuperclass();
-+ }
-+ return (Field[]) m.toArray(new Field[m.size()]);
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ private static void getJScriptInterfaceFields(Class cls, List m, Map names) {
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length; i++) {
-+ Class intf = intfs[i];
-+ boolean done = getPublicFields(intf, m, names);
-+ if (!done) {
-+ getJScriptInterfaceFields(intf, m, names);
-+ }
-+ }
-+ }
-+
-+ /*
-+ *
-+ * Process the fields in this class or interface
-+ */
-+ private static boolean getPublicFields(Class cls, List m, Map names) {
-+ Field[] fields = null;
-+ try {
-+
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's fields. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return false;
-+ }
-+
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return false;
-+ }
-+ fields = cls.getFields();
-+ } catch (SecurityException se) {
-+ return false;
-+ }
-+
-+ /*
-+ * Check for inherited fields with non-public
-+ * declaring classes. They might hide
-+ * fields from public classes or interfaces.
-+ */
-+ boolean done = true;
-+ for (int i=0; i < fields.length; i++) {
-+ Class dc = fields[i].getDeclaringClass();
-+ if (!Modifier.isPublic(dc.getModifiers())) {
-+ done = false;
-+ break;
-+ }
-+ }
-+ if (done) {
-+ /*
-+ * We're done. Spray all the fields into
-+ * the list and then we're out of here.
-+ */
-+ for (int i=0; i < fields.length; i++) {
-+ addField(m, names, fields[i]);
-+ }
-+ } else {
-+ /*
-+ * Simulate cls.getDeclaredFields() by
-+ * stripping away inherited fields.
-+ */
-+ for (int i=0; i < fields.length; i++) {
-+ Class dc = fields[i].getDeclaringClass();
-+ if (cls.equals(dc)) {
-+ addField(m, names, fields[i]);
-+ }
-+ }
-+ }
-+ return done;
-+ }
-+
-+ private static void addField(List m, Map names, Field field) {
-+ /*
-+ * Avoid adding duplicate accessible fields on
-+ * the list.
-+ */
-+ String name = field.getName();
-+ if (!names.containsKey(name)) {
-+ m.add(field);
-+ names.put(name, field);
-+ }
-+ }
-+}
-+
-+
diff --git a/java/jdk14/files/patch-liveconnect_ReplaceMethod.java b/java/jdk14/files/patch-liveconnect_ReplaceMethod.java
deleted file mode 100644
index 829e43452e6c..000000000000
--- a/java/jdk14/files/patch-liveconnect_ReplaceMethod.java
+++ /dev/null
@@ -1,93 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/ReplaceMethod.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/ReplaceMethod.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,88 @@
-+/*
-+ * @(#)ReplaceMethod.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+package sun.plugin.liveconnect;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Modifier;
-+import sun.plugin.javascript.JSClassLoader;
-+
-+public class ReplaceMethod {
-+ /*
-+ * Replace the inaccessible method by a suitable method on public
-+ * class/interface accessible to the calling JavaScript code.
-+ * Returns null if accessible method is not found.
-+ */
-+ static Method getJScriptMethod(Method start) {
-+ Class cls = start.getDeclaringClass();
-+
-+ if (Modifier.isPublic(cls.getModifiers())) {
-+ return start;
-+ }
-+
-+ String name = start.getName();
-+ Class[] params = start.getParameterTypes();
-+
-+ Method result = null;
-+ while (cls != null && result == null) {
-+ result = getPublicMethod(cls, name, params);
-+ if (result == null) {
-+ result = getJScriptInterfaceMethod(cls, name, params);
-+ }
-+ cls = cls.getSuperclass();
-+ }
-+ return result;
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ static Method getJScriptInterfaceMethod(Class cls, String name, Class[] params) {
-+ Method result = null;
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length && result == null; i++) {
-+ Class intf = intfs[i];
-+ result = getPublicMethod(intf, name, params);
-+ if (result == null) {
-+ result = getJScriptInterfaceMethod(intf, name, params);
-+ }
-+ }
-+ return result;
-+ }
-+
-+ /*
-+ *
-+ * Process the methods in this class or interface
-+ */
-+ static private Method getPublicMethod(Class cls, String name, Class[] params) {
-+ try {
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's methods. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return null;
-+ }
-+
-+ /*
-+ * This call will fail if 'cls' is in a restricted
-+ * package and we don't have permission to access
-+ * it.
-+ */
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return null;
-+ }
-+ return cls.getMethod(name, params);
-+ } catch (NoSuchMethodException nsme) {
-+ return null;
-+ } catch (SecurityException se) {
-+ return null;
-+ }
-+ }
-+}
-+
-+
diff --git a/java/jdk14/files/patch-liveconnect_SecureInvocation.java b/java/jdk14/files/patch-liveconnect_SecureInvocation.java
deleted file mode 100644
index 961414277909..000000000000
--- a/java/jdk14/files/patch-liveconnect_SecureInvocation.java
+++ /dev/null
@@ -1,351 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/SecureInvocation.java 22 Oct 2003 23:04:21 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/SecureInvocation.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
- * @(#)SecureInvocation.java 1.21 02/08/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,7 +9,8 @@
-
- import java.lang.reflect.Constructor;
- import java.lang.reflect.Field;
--import java.lang.reflect.Method;
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Modifier;
- import java.lang.Thread;
- import java.io.FilePermission;
- import java.security.AccessControlContext;
-@@ -29,7 +30,10 @@
- import java.net.URL;
- import java.net.MalformedURLException;
- import sun.plugin.util.Trace;
--import sun.plugin.services.PlatformService;
-+import sun.plugin.services.PlatformService;
-+import sun.plugin.javascript.JSClassLoader;
-+import sun.plugin.javascript.ReflectUtil;
-+
-
- /**
- * <P> SecureInvocation is for implementating nsISecureJNI which allows
-@@ -98,64 +102,64 @@
- throw e;
- }
- }
--
-- static class CallMethodThread extends Thread {
-- public CallMethodThread(int handle, Class clazz, Object obj, Method method, Object[] args,
-- String origin, boolean isUniversalBrowserRead,
-- boolean isUniversalJavaPermission) {
-- this.handle = handle;
-- this.clazz = clazz;
-- this.obj = obj;
-- this.method = method;
-- this.args = args;
-- this.origin = origin;
-- this.isUniversalBrowserRead = isUniversalBrowserRead;
-- this.isUniversalJavaPermission = isUniversalJavaPermission;
-- }
--
-- public void run() {
-- try {
-- result = CallMethod(clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-- }
-- catch(Exception e) {
-- exception = e;
-- }
-- finally {
-- PlatformService.getService().signalEvent(handle);
-- }
-- }
--
--
-- public Object getResult() throws Exception {
-- if(exception != null)
-- throw exception;
-- return result;
-- }
--
-- private Exception exception = null;
-- private Object result = null;
--
-- private int handle;
-- private Class clazz;
-- private Object obj;
-- private Method method;
-- private Object[] args;
-- private String origin;
-- private boolean isUniversalBrowserRead;
-- private boolean isUniversalJavaPermission;
--
-- }
--
-- public static Object CallMethod(final int handle, final Class clazz, final Object obj, final Method method, final Object[] args,
-- final String origin, final boolean isUniversalBrowserRead,
-- final boolean isUniversalJavaPermission)
-- throws Exception {
-- CallMethodThread callThread = new CallMethodThread(handle, clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-- callThread.start();
-- PlatformService.getService().waitEvent(handle);
-- return callThread.getResult();
-- }
--
-+
-+ static class CallMethodThread extends Thread {
-+ public CallMethodThread(int handle, Class clazz, Object obj, Method method, Object[] args,
-+ String origin, boolean isUniversalBrowserRead,
-+ boolean isUniversalJavaPermission) {
-+ this.handle = handle;
-+ this.clazz = clazz;
-+ this.obj = obj;
-+ this.method = method;
-+ this.args = args;
-+ this.origin = origin;
-+ this.isUniversalBrowserRead = isUniversalBrowserRead;
-+ this.isUniversalJavaPermission = isUniversalJavaPermission;
-+ }
-+
-+ public void run() {
-+ try {
-+ result = CallMethod(clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-+ }
-+ catch(Exception e) {
-+ exception = e;
-+ }
-+ finally {
-+ PlatformService.getService().signalEvent(handle);
-+ }
-+ }
-+
-+
-+ public Object getResult() throws Exception {
-+ if(exception != null)
-+ throw exception;
-+ return result;
-+ }
-+
-+ private Exception exception = null;
-+ private Object result = null;
-+
-+ private int handle;
-+ private Class clazz;
-+ private Object obj;
-+ private Method method;
-+ private Object[] args;
-+ private String origin;
-+ private boolean isUniversalBrowserRead;
-+ private boolean isUniversalJavaPermission;
-+
-+ }
-+
-+ public static Object CallMethod(final int handle, final Class clazz, final Object obj, final Method method, final Object[] args,
-+ final String origin, final boolean isUniversalBrowserRead,
-+ final boolean isUniversalJavaPermission)
-+ throws Exception {
-+ CallMethodThread callThread = new CallMethodThread(handle, clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-+ callThread.start();
-+ PlatformService.getService().waitEvent(handle);
-+ return callThread.getResult();
-+ }
-+
-
- /**
- * <P> Call a method on Java object with security context.
-@@ -197,8 +201,8 @@
- AccessControlContext context = new AccessControlContext(domains);
-
- // Perform the method invocation.
-- return AccessController.doPrivileged(new PrivilegedCallMethodAction(method, obj, args),
-- context);
-+ return AccessController.doPrivileged(new PrivilegedCallMethodAction(method,
-+ obj, args), context);
- } catch (Exception e) {
- Trace.liveConnectPrintException(e);
- throw e;
-@@ -323,32 +327,6 @@
- }
- }
-
--
-- /**
-- * <P> Set up a protection domain according to the origin and
-- * the other security related information.
-- */
-- private static ProtectionDomain getProtectionDomain(Class clazz,
-- String origin,
-- boolean byPassOrigin,
-- boolean allPermission)
-- throws OriginNotAllowedException, MalformedURLException
-- {
-- boolean trust = false;
--
-- // First, check if the call is allowed
-- checkLiveConnectCaller(clazz, origin, byPassOrigin);
--
-- if (allPermission)
-- {
-- return getTrustedProtectionDomain();
-- }
-- else
-- {
-- return getDefaultProtectionDomain(origin);
-- }
-- }
--
- /**
- * <P> Check if LiveConnect call is allowed at all.
- * </P>
-@@ -447,7 +425,7 @@
-
- // Obtain Java policy
- Policy policy = Policy.getPolicy();
-- CodeSource cs = new CodeSource(url, null);
-+ CodeSource cs = new CodeSource(url, (java.security.cert.Certificate[])null);
- final PermissionCollection pc = policy.getPermissions(cs);
-
- if (url == null || url.getProtocol().equals("file")) {
-@@ -516,16 +494,19 @@
-
- PrivilegedConstructObjectAction(Constructor constructor, Object[] args)
- {
-- this.constructor = constructor;
-- this.args = args;
-+ this.constructor = constructor;
-+ this.args = args;
-
-- // Ensure the argument is not null
-- if (this.args == null)
-- this.args = new Object[0];
-+ // Ensure the argument is not null
-+ if (this.args == null)
-+ this.args = new Object[0];
- }
-
- public Object run() throws Exception {
-- return constructor.newInstance(args);
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(constructor.getDeclaringClass());
-+
-+ return constructor.newInstance(args);
- }
- }
-
-@@ -543,17 +524,54 @@
-
- PrivilegedCallMethodAction(Method method, Object obj, Object[] args)
- {
-- this.method = method;
-- this.obj = obj;
-- this.args = args;
--
-- // Ensure the argument is not null
-- if (this.args == null)
-- this.args = new Object[0];
-+ this.method = method;
-+
-+ this.obj = obj;
-+ this.args = args;
-+
-+ // Ensure the argument is not null
-+ if (this.args == null)
-+ this.args = new Object[0];
- }
-
- public Object run() throws Exception {
-- return method.invoke(obj, args);
-+ /*
-+ * Browser uses reflection to collect methods/fields/constructors
-+ * through this method call. Therefore JSClassLoader is not used
-+ * in such cases. However it requires filtering to avoid exposing
-+ * inaccessible methods/fields/constructors.
-+ *
-+ * Also, Mozilla ignores abstract methods, therefore those are
-+ * replaced by the concrete class methods
-+ */
-+ if(obj instanceof Class) {
-+ String name = method.getName();
-+ Class cls = (Class)obj;
-+ if(name.equals("getMethods")) {
-+ Method[] methods = ReflectUtil.getJScriptMethods(cls);
-+ for (int i=0; i < methods.length; i++) {
-+ Method m = methods[i];
-+ if (Modifier.isAbstract(m.getModifiers())) {
-+ Class[] params = m.getParameterTypes();
-+ methods[i] = cls.getMethod(m.getName(), params);
-+ }
-+ }
-+ return methods;
-+ }else if (name.equals("getFields")) {
-+ return ReflectUtil.getJScriptFields(cls);
-+ }else if (name.equals("getConstructors")) {
-+ if (!Modifier.isPublic(cls.getModifiers()) ||
-+ !JSClassLoader.isPackageAccessible(cls)) {
-+ return new Constructor[0];
-+ }
-+ }
-+ }
-+
-+ Method actualMethod = ReplaceMethod.getJScriptMethod(method);
-+ if(actualMethod != null)
-+ return JSClassLoader.invoke(actualMethod, obj, args);
-+ else
-+ throw new NoSuchMethodException(method.getName());
- }
- }
-
-@@ -564,18 +582,20 @@
- * </P>
- */
- class PrivilegedGetFieldAction implements PrivilegedExceptionAction {
--
- Field field;
- Object obj;
-
- PrivilegedGetFieldAction(Field field, Object obj)
- {
-- this.field = field;
-- this.obj = obj;
-+ this.field = field;
-+ this.obj = obj;
- }
-
-- public Object run() throws Exception {
-- return field.get(obj);
-+ public Object run() throws Exception {
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(field.getDeclaringClass());
-+
-+ return field.get(obj);
- }
- }
-
-@@ -593,15 +613,18 @@
-
- PrivilegedSetFieldAction(Field field, Object obj, Object val)
- {
-- this.field = field;
-- this.obj = obj;
-- this.val = val;
-+ this.field = field;
-+ this.obj = obj;
-+ this.val = val;
- }
-
- public Object run() throws Exception {
-- field.set(obj, val);
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(field.getDeclaringClass());
-+
-+ field.set(obj, val);
- return null;
- }
- }
--
--
-+
-+
diff --git a/java/jdk14/files/patch-native::util.c b/java/jdk14/files/patch-native::util.c
deleted file mode 100644
index 719d1ae0e989..000000000000
--- a/java/jdk14/files/patch-native::util.c
+++ /dev/null
@@ -1,16 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/javaws/src/share/native/util.c 22 Oct 2003 23:04:17 -0000 1.1.1.1
-+++ ../../deploy/src/javaws/src/share/native/util.c 16 Jan 2004 23:50:11 -0000
-@@ -27,7 +27,10 @@
-
- /* Find size of file */
- struct stat statBuf;
-- stat(filename, &statBuf);
-+ if (stat(filename, &statBuf) == -1) {
-+ *buffer = NULL;
-+ return 0;
-+ }
- size = statBuf.st_size;
-
- /* Allocate memory for contents */
diff --git a/java/jdk14/files/patch-nspr_pth.h b/java/jdk14/files/patch-nspr_pth.h
deleted file mode 100644
index c2a1cb5d5ed1..000000000000
--- a/java/jdk14/files/patch-nspr_pth.h
+++ /dev/null
@@ -1,11 +0,0 @@
---- ../../deploy/src/plugin/oji-plugin/include/solaris/navig4/nspr/md/_pth.h 22 Oct 2003 23:04:19 -0000 1.1.1.1
-+++ ../../deploy/src/plugin/oji-plugin/include/solaris/navig4/nspr/md/_pth.h 21 Oct 2004 05:47:13 -0000
-@@ -52,7 +52,7 @@
- #define PTHREAD_MUTEXATTR_INIT pthread_mutexattr_init
- #define PTHREAD_MUTEXATTR_DESTROY pthread_mutexattr_destroy
- #define PTHREAD_MUTEX_INIT(m, a) pthread_mutex_init(&(m), &(a))
--#define PTHREAD_MUTEX_IS_LOCKED(m) (EBUSY == pthread_mutex_trylock(&(m)))
-+#define PTHREAD_MUTEX_IS_LOCKED(m) (0 != pthread_mutex_trylock(&(m)))
- #define PTHREAD_CONDATTR_INIT pthread_condattr_init
- #define PTHREAD_CONDATTR_DESTROY pthread_condattr_destroy
- #define PTHREAD_COND_INIT(m, a) pthread_cond_init(&(m), &(a))
diff --git a/java/jdk14/files/patch-plugin_DispatchImpl.java b/java/jdk14/files/patch-plugin_DispatchImpl.java
deleted file mode 100644
index abb65a60953e..000000000000
--- a/java/jdk14/files/patch-plugin_DispatchImpl.java
+++ /dev/null
@@ -1,331 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/com/DispatchImpl.java 22 Oct 2003 23:04:20 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/com/DispatchImpl.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
-- * @(#)DispatchImpl.java 1.6 03/01/23
-+ * @(#)DispatchImpl.java 1.16 04/06/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,8 +9,32 @@
-
- import sun.plugin.util.Trace;
- import sun.plugin.javascript.ocx.JSObject;
--import java.applet.Applet;
-+import sun.plugin.liveconnect.JavaScriptProtectionDomain;
- import sun.plugin.viewer.context.IExplorerAppletContext;
-+import sun.plugin.security.PluginClassLoader;
-+import java.applet.Applet;
-+import java.net.URL;
-+import java.net.MalformedURLException;
-+import java.net.InetAddress;
-+import java.net.UnknownHostException;
-+import java.net.SocketPermission;
-+import java.io.FilePermission;
-+import java.io.File;
-+import java.security.AccessControlContext;
-+import java.security.AccessController;
-+import java.security.CodeSource;
-+import java.security.Policy;
-+import java.security.ProtectionDomain;
-+import java.security.AllPermission;
-+import java.security.Permissions;
-+import java.security.Permission;
-+import java.security.PermissionCollection;
-+import java.security.PrivilegedAction;
-+import java.security.PrivilegedExceptionAction;
-+import java.security.AccessControlException;
-+import java.security.PrivilegedActionException;
-+import sun.net.www.ParseUtil;
-+import sun.security.util.SecurityConstants;
-
- /**
- * DispatchImpl encapsulates a Java Object and provides Dispatch interface
-@@ -22,14 +46,19 @@
- {
- JavaClass targetClass = null;
- Object targetObj = null;
-+ int handle = 0;
-+ int wndHandle = 0;
-+ AccessControlContext context = null;
-+ boolean isBridge = false;
-
- /*
- * Constructor
- * @param obj the object to be wrapped
- */
-- public DispatchImpl(Object obj)
-+ public DispatchImpl(Object obj, int id)
- {
- targetObj = obj;
-+ handle = id;
- }
-
- /**
-@@ -40,19 +69,87 @@
- * @param params Arguments.
- * @return Java object.
- */
-- public Object invoke(int flag, int index, Object []params)
-+ public Object invoke(final int flag, final int index, final Object []params)
-+ throws Exception
-+ {
-+ try {
-+ //No security constraints in case of ActiveX bridge application
-+ if(isBridge)
-+ return invokeImpl(flag, index, params);
-+
-+ if(context == null) {
-+ context = createContext();
-+ }
-+
-+ // Invoke the method within the applet sand box security restricitions
-+ return AccessController.doPrivileged(
-+ new PrivilegedExceptionAction() {
-+ public Object run() throws Exception{
-+ return invokeImpl(flag, index, params);
-+ }
-+ }, context
-+ );
-+ }catch(Exception exc) {
-+ Throwable cause = exc.getCause();
-+ if(cause == null) {
-+ cause = exc;
-+ }
-+
-+ Trace.liveConnectPrintException(cause);
-+ throw new Exception(cause.toString());
-+ }
-+ }
-+
-+ public AccessControlContext createContext() {
-+ try {
-+ ProtectionDomain[] domains = new ProtectionDomain[1];
-+ //Obtain the java code origin
-+ ProtectionDomain pd = (ProtectionDomain)AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ return targetObj.getClass().getProtectionDomain();
-+ }
-+ });
-+
-+ CodeSource cs = null;
-+ URL url = null;
-+ if(pd != null)
-+ cs = pd.getCodeSource();
-+ if(cs != null)
-+ url = cs.getLocation();
-+
-+ domains[0] = getJSProtectionDomain(url, targetObj.getClass());
-+ return new AccessControlContext(domains);
-+ }catch(Exception exc) {
-+ Trace.liveConnectPrintException(exc);
-+ }
-+
-+ return null;
-+ }
-+
-+ /**
-+ * Invoke a method according to the method index.
-+ *
-+ * @param flag Invoke flag
-+ * @param index Method index
-+ * @param params Arguments.
-+ * @return Java object.
-+ */
-+ public Object invokeImpl(int flag, int index, Object []params)
- throws Exception
- {
- Object retObj = null;
- Dispatcher disp = null;
- try {
-- convertParams(params);
-+ if(params != null)
-+ convertParams(params);
- disp = targetClass.getDispatcher(flag, index, params);
-- return disp.invoke(targetObj, params);
-- }
-- catch (Throwable e)
-- {
-- //e.printStackTrace();
-+ if(disp != null) {
-+ retObj = disp.invoke(targetObj, params);
-+ if(retObj != null)
-+ retObj = Utils.convertReturn(disp.getReturnType(), retObj, handle);
-+ }
-+ return retObj;
-+ } catch (Throwable e) {
- Throwable cause = e.getCause();
- if(cause == null) {
- cause = e;
-@@ -82,11 +179,39 @@
- return targetClass;
- }
-
-+ public int getReturnType(int id){
-+ return targetClass.getReturnType(id);
-+ }
-+
-+ public int getIdForName(final String name) throws Exception{
-+ try {
-+ //No security constraints in case of ActiveX bridge application
-+ if(isBridge)
-+ return getIdForNameImpl(name);
-+
-+ if(context == null) {
-+ context = createContext();
-+ }
-+
-+ // Invoke the method within the applet sand box security restricitions
-+ Integer retVal = (Integer)AccessController.doPrivileged(
-+ new PrivilegedExceptionAction() {
-+ public Object run() throws Exception{
-+ return new Integer(getIdForNameImpl(name));
-+ }
-+ }, context
-+ );
-+ return retVal.intValue();
-+ }catch(PrivilegedActionException pe) {
-+ }
-+
-+ return -1;
-+ }
-
- /*
- *
- */
-- public int getIdForName(String name) throws Exception{
-+ public int getIdForNameImpl(String name) throws Exception{
- int id = -1;
-
- if(targetClass == null && targetObj != null) {
-@@ -103,27 +228,122 @@
- }
-
- /*
-- *
-+ * Unwraps the wrapped java object arguments
- */
- private void convertParams(Object []params) {
- for(int i=0;i<params.length;i++) {
- if(params[i] != null && params[i] instanceof DispatchImpl) {
- params[i] = ((DispatchImpl)params[i]).getWrappedObject();
- } else if(params[i] != null && params[i] instanceof DispatchClient){
-- JSObject jsObj = new JSObject((DispatchClient)params[i]);
-- jsObj.setIExplorerAppletContext((IExplorerAppletContext)
-+ JSObject jsObj = null;
-+ if (!isBridge) {
-+ jsObj = new JSObject((DispatchClient)params[i]);
-+ jsObj.setIExplorerAppletContext((IExplorerAppletContext)
- ((Applet)targetObj).getAppletContext());
-+ } else {
-+ jsObj = new JSObject((DispatchClient)params[i], handle);
-+ }
- params[i] = jsObj;
- }
- }
- }
-
-+ /**
-+ * Returns a protection domain that represents the default permission
-+ * for a given URL.
-+ *
-+ * @param urlString URL
-+ * @return protection domain.
-+ */
-+ public static ProtectionDomain getJSProtectionDomain(URL url, Class clazz)
-+ throws MalformedURLException {
-+
-+ // Obtain default java applet policy
-+ Policy policy = (Policy)AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ return Policy.getPolicy();
-+ }
-+ });
-+
-+ CodeSource cs = new CodeSource(null, (java.security.cert.Certificate[])null);
-+ final PermissionCollection pc = policy.getPermissions(cs);
-+ if(url != null) {
-+ Permission p;
-+ String path = null;
-+ try {
-+ p = url.openConnection().getPermission();
-+ } catch (java.io.IOException ioe) {
-+ p = null;
-+ }
-+
-+ if (p instanceof FilePermission) {
-+ path = p.getName();
-+ } else if ((p == null) && (url.getProtocol().equals("file"))) {
-+ path = url.getFile().replace('/', File.separatorChar);
-+ path = ParseUtil.decode(path);
-+ } else if (p instanceof SocketPermission) {
-+ /*
-+ Socket permission to connect back to the host
-+ */
-+ String host = url.getHost();
-+ pc.add(new SocketPermission(host,
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ }
-+
-+ if(path != null &&
-+ (clazz.getClassLoader() instanceof PluginClassLoader)) {
-+ //We need to add an additional permission to read recursively
-+ if (path.endsWith(File.separator)) {
-+ path += "-";
-+ } else {
-+ int endIndex = path.lastIndexOf(File.separatorChar);
-+ if (endIndex != -1)
-+ path = path.substring(0, endIndex+1) + "-";
-+ }
-+
-+ pc.add(new FilePermission(path, SecurityConstants.FILE_READ_ACTION));
-+
-+ /*
-+ Socket permission to connect back to the "localhost"
-+ */
-+ pc.add(new SocketPermission("localhost",
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ try {
-+ String host = InetAddress.getLocalHost().getHostName();
-+ pc.add(new SocketPermission(host,
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ } catch (UnknownHostException uhe) {
-+ }
-+ return null;
-+ }
-+ });
-+ }
-+ }
-+
-+ return new JavaScriptProtectionDomain(pc);
-+ }
-+
- public String toString() {
- if(targetObj != null) {
- return targetObj.toString();
- }
- return null;
- }
-+
-+ public int getWindowHandle() {
-+ if(wndHandle == 0) {
-+ wndHandle = getWindowHandle(handle);
-+ }
-+ return wndHandle;
-+ }
-+
-+ protected void setBridge() {
-+ isBridge = true;
-+ }
-+
-+ native int getWindowHandle(int id);
- }
-
-
diff --git a/java/jdk14/files/patch-plugin_FileList.gmk b/java/jdk14/files/patch-plugin_FileList.gmk
deleted file mode 100644
index c5fca27bdda9..000000000000
--- a/java/jdk14/files/patch-plugin_FileList.gmk
+++ /dev/null
@@ -1,22 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/make/plugin/java/FileList.gmk 7 Nov 2003 12:15:52 -0000 1.2
-+++ ../../deploy/make/plugin/java/FileList.gmk 3 Dec 2004 03:56:58 -0000 1.3
-@@ -86,6 +86,9 @@
- \
- sun/plugin/javascript/JSObject.java \
- sun/plugin/javascript/JSContext.java \
-+ sun/plugin/javascript/JSClassLoader.java \
-+ sun/plugin/javascript/ReflectUtil.java \
-+ sun/plugin/javascript/JSInvoke.java \
- \
- sun/plugin/javascript/navig/Navigator.java \
- sun/plugin/javascript/navig/Document.java \
-@@ -125,6 +128,7 @@
- sun/plugin/liveconnect/JavaScriptPermission.java \
- sun/plugin/liveconnect/SecurityContextHelper.java \
- sun/plugin/liveconnect/LiveConnect.java \
-+ sun/plugin/liveconnect/ReplaceMethod.java \
- \
- sun/plugin/extension/ExtensionInstallationImpl.java \
- sun/plugin/extension/ExtensionInstaller.java \
diff --git a/java/jdk14/files/patch-plugin_MethodDispatcher.java b/java/jdk14/files/patch-plugin_MethodDispatcher.java
deleted file mode 100644
index 57e6d22b5a63..000000000000
--- a/java/jdk14/files/patch-plugin_MethodDispatcher.java
+++ /dev/null
@@ -1,41 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/com/MethodDispatcher.java 22 Oct 2003 23:04:20 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/com/MethodDispatcher.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
-- * @(#)MethodDispatcher.java 1.5 03/01/23
-+ * @(#)MethodDispatcher.java 1.10 04/06/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,6 +9,7 @@
-
- import java.lang.reflect.Method;
- import sun.plugin.util.Trace;
-+import sun.plugin.javascript.JSClassLoader;
-
- /**
- * A <code>MethodDispatcher</code> provides information about,
-@@ -47,11 +48,16 @@
- Object retObj = null;
- if(method != null && obj != null) {
- Trace.msgLiveConnectPrintln("com.method.invoke", new Object[] {method});
-+ Class theClass = obj.getClass();
- Object[] params = TypeConverter.convertObjectArray(
- method.getParameterTypes(), args);
-- retObj = Utils.convertReturn( method.getReturnType(),
-- method.invoke(obj, params ));
-+ // check if the class is private and the method is public
-+ retObj = JSClassLoader.invoke(method, obj, params);
- }
- return retObj;
-+ }
-+
-+ public Class getReturnType() {
-+ return method.getReturnType();
- }
- }
diff --git a/java/jdk14/files/patch-plugin_ns600_nscore.h b/java/jdk14/files/patch-plugin_ns600_nscore.h
deleted file mode 100644
index 9e4bcacf650a..000000000000
--- a/java/jdk14/files/patch-plugin_ns600_nscore.h
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns600/nscore.h.orig Fri Jul 30 18:00:04 2004
-+++ ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns600/nscore.h Fri Jul 30 23:32:31 2004
-@@ -163,7 +163,7 @@
- */
-
- /* under Metrowerks (Mac), we don't have autoconf yet */
--#ifdef __MWERKS__
-+#if defined(__MWERKS__) || defined(NS_UNIX)
- #define HAVE_CPP_SPECIALIZATION
- #define HAVE_CPP_PARTIAL_SPECIALIZATION
- #define HAVE_CPP_MODERN_SPECIALIZE_TEMPLATE_SYNTAX
diff --git a/java/jdk14/files/patch-plugin_ns610_nscore.h b/java/jdk14/files/patch-plugin_ns610_nscore.h
deleted file mode 100644
index de8cc76e5fa3..000000000000
--- a/java/jdk14/files/patch-plugin_ns610_nscore.h
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns610/nscore.h.orig Fri Jul 30 18:00:05 2004
-+++ ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns610/nscore.h Fri Jul 30 23:23:36 2004
-@@ -163,7 +163,7 @@
- */
-
- /* under Metrowerks (Mac), we don't have autoconf yet */
--#ifdef __MWERKS__
-+#if defined(__MWERKS__) || defined(NS_UNIX)
- #define HAVE_CPP_SPECIALIZATION
- #define HAVE_CPP_PARTIAL_SPECIALIZATION
- #define HAVE_CPP_MODERN_SPECIALIZE_TEMPLATE_SYNTAX
diff --git a/java/jdk14/files/patch-vm::os_bsd.hpp b/java/jdk14/files/patch-vm::os_bsd.hpp
deleted file mode 100644
index cab94f46e4d3..000000000000
--- a/java/jdk14/files/patch-vm::os_bsd.hpp
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/os/bsd/vm/os_bsd.hpp.orig Wed Oct 20 16:01:08 2004
-+++ ../../hotspot/src/os/bsd/vm/os_bsd.hpp Wed Oct 20 16:01:30 2004
-@@ -353,7 +353,7 @@
- bool trylock() {
- verify();
- int status = pthread_mutex_trylock(_mutex);
-- if (status == EBUSY)
-+ if (status == EBUSY || status == EDEADLK)
- return false;
- assert(status == 0, "pthread_mutex_trylock");
- #ifndef PRODUCT
diff --git a/java/jdk14/pkg-plist b/java/jdk14/pkg-plist
index 32bbfdbb4198..901429fa23fb 100644
--- a/java/jdk14/pkg-plist
+++ b/java/jdk14/pkg-plist
@@ -893,6 +893,7 @@ jdk%%JDK_VERSION%%/jre/Welcome.html
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/bin/ControlPanel
jdk%%JDK_VERSION%%/jre/bin/java
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/bin/java_vm
+%%MINIMAL:%%%%DEBUG:%%jdk%%JDK_VERSION%%/jre/bin/java_vm_g
jdk%%JDK_VERSION%%/jre/bin/keytool
jdk%%JDK_VERSION%%/jre/bin/kinit
jdk%%JDK_VERSION%%/jre/bin/klist
@@ -980,6 +981,7 @@ jdk%%JDK_VERSION%%/jre/lib/i386/libioser12.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjaas_unix.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjava.so
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/lib/i386/libjavaplugin_jni.so
+%%MINIMAL:%%%%DEBUG:%%jdk%%JDK_VERSION%%/jre/lib/i386/libjavaplugin_jni_g.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjawt.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjcov.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjdwp.so
diff --git a/java/jdk15/Makefile b/java/jdk15/Makefile
index 169a67f7b96d..31744bfcb4b1 100644
--- a/java/jdk15/Makefile
+++ b/java/jdk15/Makefile
@@ -7,7 +7,6 @@
PORTNAME= jdk
PORTVERSION= ${JDK_VERSION}p${JDK_PATCHSET_VERSION}
-PORTREVISION= 7
CATEGORIES= java devel
MASTER_SITES= # http://www.sun.com/software/java2/download.html
# http://www.eyesbeyond.com/freebsddom/java/jdk14.html
@@ -32,7 +31,7 @@ RUN_DEPENDS+= ${X11BASE}/lib/X11/fonts/URW/fonts.dir:${PORTSDIR}/x11-fonts/urwfo
WRKSRC= ${WRKDIR}/control/make
JDK_VERSION= 1.4.2
-JDK_PATCHSET_VERSION= 6
+JDK_PATCHSET_VERSION= 7
LATEST_LINK= jdk14
SUN_LINUX_JDK_VERSION= 1.4.2
@@ -315,6 +314,9 @@ do-install:
.endif
post-install:
+.if !defined(MINIMAL)
+ ${FIND} "${PREFIX}/jdk${JDK_VERSION}/jre/plugin" -type d | ${XARGS} ${CHMOD} a+rx
+.endif
@${LOCALBASE}/bin/registervm "${PREFIX}/jdk${JDK_VERSION}/bin/java # FREEBSD-JDK${JDK_VERSION}"
@${SED} -e "s:%%JRE_HOME%%:${PREFIX}/jdk${JDK_VERSION}/jre:g" \
< ${FILESDIR}/pkg-install.in > ${PKGINSTALL}
diff --git a/java/jdk15/distinfo b/java/jdk15/distinfo
index 9fb0a0721197..fb62f1cbad29 100644
--- a/java/jdk15/distinfo
+++ b/java/jdk15/distinfo
@@ -2,5 +2,5 @@ MD5 (j2sdk-1_4_2-src-scsl.zip) = 387ae674dcd686f3a7a477c191aa8b65
SIZE (j2sdk-1_4_2-src-scsl.zip) = 49269919
MD5 (j2sdk-1_4_2-bin-scsl.zip) = 24877ff50ae66744090c3723968bb7dc
SIZE (j2sdk-1_4_2-bin-scsl.zip) = 2513462
-MD5 (bsd-jdk14-patches-6.tar.gz) = fe01a66ce4e8425f169c1b4a88d08f87
-SIZE (bsd-jdk14-patches-6.tar.gz) = 1068798
+MD5 (bsd-jdk14-patches-7.tar.gz) = fe76afc2dd8651350a2f0e221d928fa5
+SIZE (bsd-jdk14-patches-7.tar.gz) = 1137785
diff --git a/java/jdk15/files/patch-awt_Component.c b/java/jdk15/files/patch-awt_Component.c
deleted file mode 100644
index db768c611349..000000000000
--- a/java/jdk15/files/patch-awt_Component.c
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/solaris/native/sun/awt/awt_Component.c.orig 27 Oct 2003 12:16:41 -0000 1.4
-+++ ../../j2se/src/solaris/native/sun/awt/awt_Component.c 1 Mar 2004 21:36:45 -0000 1.5
-@@ -1179,7 +1179,7 @@
- }
- XtVaSetValues(to, XmNtraversalOn, True, NULL);
- }
-- } else if (from != NULL) {
-+ } else if (from != NULL && to != NULL) {
- // disable the tree starting from uncommon part to 'from'
- if (parents_from[index] == parents_to[index]) {
- if (index == count_from - 1) {
diff --git a/java/jdk15/files/patch-awt_fontmanager_fontObject.cpp b/java/jdk15/files/patch-awt_fontmanager_fontObject.cpp
deleted file mode 100644
index 3efc10e85b68..000000000000
--- a/java/jdk15/files/patch-awt_fontmanager_fontObject.cpp
+++ /dev/null
@@ -1,53 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/fontObject.cpp.orig Wed Jul 7 09:33:52 2004
-+++ ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/fontObject.cpp Wed Jul 7 13:26:03 2004
-@@ -416,7 +416,11 @@
- fUseCount += 1;
-
- if (length > 0 && fFileSize > 0) {
-- assert(offset < fFileSize);
-+ if (offset >= fFileSize) {
-+ fUseCount--;
-+ return NULL;
-+ }
-+
- if ((offset + length) > fFileSize)
- length = fFileSize - offset;
-
-@@ -431,13 +435,14 @@
- "fileFontObject::ReadChunk(UInt32,UInt32,void*)\n"
- );
- #endif
-+ fUseCount--;
- return NULL;
- }
-
- off_t err = lseek(fFile, offset, SEEK_SET);
- #ifdef DEBUG
- if (err == (off_t)-1) {
-- fprintf(stderr, "seek(%d) returned %d\n", offset, (int) err);
-+ fprintf(stderr, "seek(%ld) returned %d\n", offset, (int) err);
- }
- #endif
-
-@@ -448,7 +453,7 @@
- int tellvalue = lseek(fFile, 0, SEEK_END);
- #ifdef DEBUG
- fprintf(stderr,
-- "<%s> of %d, ln %d, rd %d, sz %d, tell %d, err %d\n",
-+ "<%s> of %ld, ln %ld, rd %d, sz %ld, tell %d, err %d\n",
- (char *)fFileName, offset, length, (int)bytesRead,
- fFileSize, tellvalue, (int) err);
- #endif
-@@ -1457,7 +1462,9 @@
- return false;
- }
-
-- this->ReadChunk(sizeof theHeader, fFontCount * sizeof *offsets, offsets);
-+ if (this->ReadChunk(sizeof theHeader, fFontCount * sizeof *offsets, offsets) == NULL) {
-+ return false;
-+ }
- for (int i=0; i<fFontCount; i++) {
- offsets[i] = GET32(offsets[i]);
- }
diff --git a/java/jdk15/files/patch-awt_fontmanager_t2kScalerContext.cpp b/java/jdk15/files/patch-awt_fontmanager_t2kScalerContext.cpp
deleted file mode 100644
index 7f39f7cceabb..000000000000
--- a/java/jdk15/files/patch-awt_fontmanager_t2kScalerContext.cpp
+++ /dev/null
@@ -1,21 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/t2kScalerContext.cpp.orig Fri Jul 30 18:00:09 2004
-+++ ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/t2kScalerContext.cpp Fri Jul 30 22:11:36 2004
-@@ -937,14 +937,14 @@
- CMAPMapper::CharsToGlyphs(
- int count, const Unicode16 unicodes[], UInt32 glyphs[]) const
- {
-- ConvertUnicodeToGlyphs(*font, (unsigned char *)cmap, count, unicodes, glyphs);
-+ ConvertUnicodeToGlyphs(*font, (byte*&)cmap, count, unicodes, glyphs);
- }
-
- void
- CMAPMapper::CharsToGlyphs(
- int count, const Unicode32 unicodes[], UInt32 glyphs[]) const
- {
-- ConvertUnicodeToGlyphs(*font, (unsigned char *)cmap, count, unicodes, glyphs);
-+ ConvertUnicodeToGlyphs(*font, (byte*&)cmap, count, unicodes, glyphs);
- }
-
- //////////////////////////////////////////////////////////////////////////////
diff --git a/java/jdk15/files/patch-deploy::Makefile b/java/jdk15/files/patch-deploy::Makefile
deleted file mode 100644
index a34bfa0c9d71..000000000000
--- a/java/jdk15/files/patch-deploy::Makefile
+++ /dev/null
@@ -1,46 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/make/Makefile.orig Tue Jan 27 18:54:56 2004
-+++ ../../deploy/make/Makefile Tue Jan 27 18:58:08 2004
-@@ -24,17 +24,29 @@
- DEPLOY_TOPDIR=..
- include $(BUILDDIR)/common/Defs.gmk
-
-+ifdef NO_PLUGIN
-+BUILD_PLUGIN= false
-+else
-+BUILD_PLUGIN= true
-+endif
-+
-+ifdef NO_JAVAWS
-+BUILD_JAVAWS= false
-+else
-+BUILD_JAVAWS= true
-+endif
-+
- all::
- @$(ECHO) "$(PLATFORM) $(ARCH) $(RELEASE) deploy build started: $(shell $(DATE) '+%y-%m-%d %H:%M')"
-
--BUILD_PLUGIN = true
--
- #
- # Core.
- #
- JAVAWS_SUBDIR = javaws
- PLUGIN_SUBDIR = plugin
-+ifeq ($(BUILD_JAVAWS), true)
- SUBDIRS = $(JAVAWS_SUBDIR)
-+endif
- ifeq ($(BUILD_PLUGIN), true)
- SUBDIR += $(PLUGIN_SUBDIR)
- endif
-@@ -47,7 +59,9 @@
- done
-
- javaws-all: sanity-javaws
-+ ifeq ($(BUILD_JAVAWS), true)
- $(CD) $(BUILDDIR)/javaws ; $(MAKE) installer-int dev-all doc aubundle
-+ endif
-
- plugin-all: sanity-plugin
- ifeq ($(BUILD_PLUGIN), true)
diff --git a/java/jdk15/files/patch-font.properties.zh_TW.bsd b/java/jdk15/files/patch-font.properties.zh_TW.bsd
deleted file mode 100644
index a142781b2ee2..000000000000
--- a/java/jdk15/files/patch-font.properties.zh_TW.bsd
+++ /dev/null
@@ -1,302 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/solaris/classes/sun/awt/motif/font.properties.zh_TW.bsd.orig 16 Aug 2002 06:04:59 -0000 1.1
-+++ ../../j2se/src/solaris/classes/sun/awt/motif/font.properties.zh_TW.bsd 1 Mar 2004 21:40:08 -0000 1.2
-@@ -1,235 +1,178 @@
-+# %W% %E%
- #
--# @(#)font.properties.zh 1.0 00/06/20
--#
--# Copyright 2000 by Sun Microsystems, Inc.,
--# 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
--# All rights reserved.
--#
--# This software is the confidential and proprietary information
--# of Sun Microsystems, Inc. ("Confidential Information"). You
--# shall not disclose such Confidential Information and shall use
--# it only in accordance with the terms of the license agreement
--# you entered into with Sun.
--#
--
--#
--# AWT Font default Properties for Simplified Chinese TurboLinux 6.0 and higher
-+# Copyright 2002 Sun Microsystems, Inc. All rights reserved.
- #
-
--# Serif font definition
-+# Component Font Mappings For RedhatLinux 8.0/zh_TW
- #
- serif.0=-b&h-lucidabright-medium-r-normal--*-%d-*-*-p-*-iso8859-1
--serif.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.italic.0=-b&h-lucidabright-medium-i-normal--*-%d-*-*-p-*-iso8859-1
--serif.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.bold.0=-b&h-lucidabright-demibold-r-normal--*-%d-*-*-p-*-iso8859-1
--serif.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.bolditalic.0=-b&h-lucidabright-demibold-i-normal--*-%d-*-*-p-*-iso8859-1
--serif.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# SansSerif font definition
--#
- sansserif.0=-b&h-lucidasans-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.italic.0=-b&h-lucidasans-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.bold.0=-b&h-lucidasans-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.bolditalic.0=-b&h-lucidasans-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Monospaced font definition
--#
- monospaced.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--monospaced.italic.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.italic.0=-b&h-lucidatypewriter-medium-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+monospaced.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- monospaced.bold.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--monospaced.bolditalic.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.bolditalic.0=-b&h-lucidatypewriter-bold-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+monospaced.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Dialog font definition
--#
- dialog.0=-b&h-lucidasans-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.italic.0=-b&h-lucidasans-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.bold.0=-b&h-lucidasans-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.bolditalic.0=-b&h-lucidasans-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# DialogInput font definition
--#
- dialoginput.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--dialoginput.italic.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.italic.0=-b&h-lucidatypewriter-medium-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+dialoginput.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialoginput.bold.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
--
--dialoginput.bolditalic.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
-+dialoginput.bolditalic.0=-b&h-lucidatypewriter-bold-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+dialoginput.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Default font definition
-+# Missing Glyph Character
- #
- default.char=274f
-
--# name aliases
--#
--# alias.timesroman=serif
--# alias.helvetica=sansserif
--# alias.courier=monospaced
--
--# for backward compatibility
--#
--#zapfdingbats.0=-monotype-monotype sorts-regular-r---*-%d-*-*-p-*-adobe-dingbats
--
--# Static FontCharset info.
--#
--# This information is used by the font which is not indexed by Unicode.
--# Such fonts can use their own subclass of FontCharset.
--#
--# This information can be overriden by describing more specific style.
--# For example
--#
--# fontcharset.serif.plain.3=SpecialSymbols
--# means serif.plain.3 font's index can be retrieved with the convert() method
--# of instance of SpecialSymbols and what kind of characters serif.plain.3 font
--# has can be judged with the isCovered() method of instance of SpecialSymbols.
-+# Component Font Character Encodings
- #
- fontcharset.serif.0=sun.io.CharToByteISO8859_1
--fontcharset.serif.1=sun.io.CharToByteMS950
-+fontcharset.serif.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.sansserif.0=sun.io.CharToByteISO8859_1
--fontcharset.sansserif.1=sun.io.CharToByteMS950
-+fontcharset.sansserif.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.monospaced.0=sun.io.CharToByteISO8859_1
--fontcharset.monospaced.1=sun.io.CharToByteMS950
-+fontcharset.monospaced.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.dialog.0=sun.io.CharToByteISO8859_1
--fontcharset.dialog.1=sun.io.CharToByteMS950
-+fontcharset.dialog.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.dialoginput.0=sun.io.CharToByteISO8859_1
--fontcharset.dialoginput.1=sun.io.CharToByteMS950
-+fontcharset.dialoginput.1=sun.io.CharToByteUnicodeBigUnmarked
-
--# exclusion info.
--#
--# This information describe exclusion ranges for each fonts.
--#
--# 'exclusion.serif.plain.0' overrides 'exclusion.serif.0', and
--# 'exclusion.serif.0' overrides exclusion.0, and so on.
-+# Exclusion Ranges
- #
-
--# XFontSet string
--# X11 only properties
-+# XFontSet Information
- #
- fontset.serif.plain=\
- -b&h-lucidabright-medium-r-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.italic=\
- -b&h-lucidabright-medium-i-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.bold=\
- -b&h-lucidabright-demibold-r-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.bolditalic=\
- -b&h-lucidabright-demibold-i-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
--
--# SansSerif font definition
--#
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.plain=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.italic=\
- -b&h-lucida-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.bold=\
---b&h-lucida-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.bolditalic=\
---b&h-lucida-bold-i-normal-snas-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# Monospaced font definition
--#
- fontset.monospaced.plain=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.italic=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.bold=\
---b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-,1\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.bolditalic=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# Dialog font definition
--#
- fontset.dialog.italic=\
- -b&h-lucida-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.bold=\
- -b&h-lucida-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.bolditalic=\
- -b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.plain=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# DialogInput font definition
--#
- fontset.dialoginput.italic=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.bold=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.bolditalic=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.plain=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--#
- fontset.default=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-+
-+filename.-arphic_technology_co.-ar_pl_mingti2l_big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1=/usr/local/share/fonts/TrueType/bsmi00lp.ttf
diff --git a/java/jdk15/files/patch-hpi_monitor_md.c b/java/jdk15/files/patch-hpi_monitor_md.c
deleted file mode 100644
index ca874dd9cd35..000000000000
--- a/java/jdk15/files/patch-hpi_monitor_md.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- ../../j2se/src/solaris/hpi/native_threads/src/monitor_md.c 22 Oct 2003 23:03:43 -0000 1.1.1.2
-+++ ../../j2se/src/solaris/hpi/native_threads/src/monitor_md.c 21 Oct 2004 05:42:52 -0000
-@@ -129,7 +129,7 @@
- mid->monitor_owner = self;
- mid->entry_count = 1;
- return SYS_OK;
-- } else if (err == EBUSY) { /* it's already locked */
-+ } else if (err == EBUSY || err == EDEADLK) { /* it's already locked */
- if (mid->monitor_owner == self) {
- mid->entry_count++;
- return SYS_OK;
diff --git a/java/jdk15/files/patch-interpreter_bytecodes.hpp b/java/jdk15/files/patch-interpreter_bytecodes.hpp
deleted file mode 100644
index 112722cac07e..000000000000
--- a/java/jdk15/files/patch-interpreter_bytecodes.hpp
+++ /dev/null
@@ -1,24 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/share/vm/interpreter/bytecodes.hpp 22 Oct 2003 23:05:03 -0000 1.1.1.3
-+++ ../../hotspot/src/share/vm/interpreter/bytecodes.hpp 12 Oct 2004 05:27:27 -0000
-@@ -6,6 +6,9 @@
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-+
-+#include <limits.h>
-+
- // Bytecodes specifies all bytecodes used in the VM and
- // provides utility functions to get bytecode attributes.
-
-@@ -236,7 +239,8 @@
- // Platform specific JVM bytecodes
- #include "incls/_bytecodes_pd.hpp.incl"
-
-- number_of_codes
-+ number_of_codes,
-+ WIDTH_HINT = INT_MAX
- };
-
- private:
diff --git a/java/jdk15/files/patch-interpreter_shared.hpp b/java/jdk15/files/patch-interpreter_shared.hpp
deleted file mode 100644
index 25feb1ff8da9..000000000000
--- a/java/jdk15/files/patch-interpreter_shared.hpp
+++ /dev/null
@@ -1,38 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/share/vm/interpreter/shared.hpp 22 Oct 2003 23:05:05 -0000 1.1.1.2
-+++ ../../hotspot/src/share/vm/interpreter/shared.hpp 10 Oct 2004 05:03:55 -0000
-@@ -41,19 +41,17 @@
- // to control the C++ namespace.
- class OptoReg VALUE_OBJ_CLASS_SPEC {
- public:
-- enum Name {
-- // Chunk 0
-+ typedef int Name;
- #ifdef COMPILER2
-- Physical = AdlcVMDeps::Physical, // Start of physical regs
-+ static const Name Physical = AdlcVMDeps::Physical; // Start of physical regs
- #endif
- // A few oddballs at the edge of the world
-- Special = -2, // All special (not allocated) values
-- Bad = -1 // Not a register
-- };
-+ static const Name Special = -2; // All special (not allocated) values
-+ static const Name Bad = -1; // Not a register
-
- // Increment a register number. As in:
- // "for ( OptoReg::Name i; i=Control; i = add(i,1) ) ..."
-- static Name add( Name x, int y ) { return Name(x+y); }
-+ static Name add( Name x, int y ) { return (x+y); }
-
- // (We would like to have an operator+ for RegName, but it is not
- // a class, so this would be illegal in C++.)
-@@ -70,7 +68,7 @@
- // when we do not yet know how big the frame will be.
- class VMReg VALUE_OBJ_CLASS_SPEC {
- public:
-- enum Name { };
-+ typedef int Name;
- };
-
-
diff --git a/java/jdk15/files/patch-io_io_util.h b/java/jdk15/files/patch-io_io_util.h
deleted file mode 100644
index 80f00417aa2b..000000000000
--- a/java/jdk15/files/patch-io_io_util.h
+++ /dev/null
@@ -1,21 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/java/io/io_util.h.orig Wed Jul 21 08:32:49 2004
-+++ ../../j2se/src/share/native/java/io/io_util.h Wed Jul 21 08:37:54 2004
-@@ -10,7 +10,15 @@
-
- extern jfieldID IO_fd_fdID;
-
--#if !defined(O_DSYNC) || !defined(O_SYNC)
-+#ifdef _BSD_SOURCE
-+#include <fcntl.h>
-+#ifndef O_SYNC
-+#define O_SYNC O_FSYNC
-+#endif
-+#ifndef O_DSYNC
-+#define O_DSYNC O_FSYNC
-+#endif
-+#elif !defined(O_DSYNC) || !defined(O_SYNC)
- #define O_SYNC (0x0800)
- #define O_DSYNC (0x2000)
- #endif
diff --git a/java/jdk15/files/patch-javascript_JSClassLoader.java b/java/jdk15/files/patch-javascript_JSClassLoader.java
deleted file mode 100644
index 1e3a9ad3080b..000000000000
--- a/java/jdk15/files/patch-javascript_JSClassLoader.java
+++ /dev/null
@@ -1,243 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSClassLoader.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSClassLoader.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,238 @@
-+/*
-+ * @(#)JSClassLoader.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+
-+package sun.plugin.javascript;
-+
-+import java.security.AllPermission;
-+import java.security.AccessController;
-+import java.security.PermissionCollection;
-+import java.security.SecureClassLoader;
-+import java.security.PrivilegedExceptionAction;
-+import java.security.CodeSource;
-+import java.io.InputStream;
-+import java.io.BufferedInputStream;
-+import java.io.IOException;
-+import java.net.URL;
-+import java.net.URLConnection;
-+import java.net.HttpURLConnection;
-+import java.lang.reflect.Method;
-+import java.lang.reflect.InvocationTargetException;
-+import java.lang.reflect.AccessibleObject;
-+import sun.net.www.ParseUtil;
-+import sun.security.util.SecurityConstants;
-+
-+/*
-+ * Create a trampoline class for JavaScript to Java
-+ * method invocations.
-+ *
-+ */
-+public final class JSClassLoader extends SecureClassLoader {
-+ private static String JS_PROXY_PKG = "sun.plugin.javascript.invoke.";
-+ private static String TRAMPOLINE = JS_PROXY_PKG + "JSInvoke";
-+ private static Method bounce;
-+
-+ /*
-+ * Bounce through the trampoline.
-+ */
-+ public static Object invoke(Method m, Object obj, Object[] params)
-+ throws Exception {
-+ try {
-+ return bounce().invoke(null, new Object[] {m, obj, params});
-+ } catch (InvocationTargetException ie) {
-+ Throwable t = ie.getCause();
-+
-+ if (t instanceof InvocationTargetException) {
-+ throw (InvocationTargetException)t;
-+ } else {
-+ throw ie;
-+ }
-+ }
-+ }
-+
-+ /**
-+ * Check the package access permission by giving a class
-+ *
-+ * @param clazz: The Class object trying to get access to
-+ *
-+ */
-+ public static void checkPackageAccess(Class clazz) {
-+ String clsname = clazz.getName();
-+ int index = clsname.lastIndexOf(".");
-+ if (index != -1) {
-+ String pkgname = clsname.substring(0, index);
-+ SecurityManager s = System.getSecurityManager();
-+ if (s != null) {
-+ s.checkPackageAccess(pkgname);
-+ }
-+ }
-+ }
-+
-+ public static boolean isPackageAccessible(Class clazz) {
-+ try {
-+ checkPackageAccess(clazz);
-+ } catch (SecurityException e) {
-+ return false;
-+ }
-+ return true;
-+ }
-+
-+
-+ private synchronized static Method bounce() throws Exception {
-+ if (bounce == null) {
-+ bounce = (Method) AccessController.doPrivileged(new PrivilegedExceptionAction() {
-+ public Object run() throws Exception {
-+ Class[] types;
-+ Class t = getTrampoline();
-+ Method b;
-+
-+ types = new Class[] {Method.class, Object.class, Object[].class};
-+ b = t.getDeclaredMethod("invoke", types);
-+ ((AccessibleObject)b).setAccessible(true);
-+ return b;
-+ }
-+ });
-+ }
-+ return bounce;
-+ }
-+
-+ private static Class getTrampoline() {
-+ try {
-+ return Class.forName(TRAMPOLINE, true, new JSClassLoader());
-+ } catch (ClassNotFoundException e) {
-+ }
-+ return null;
-+ }
-+
-+
-+ protected synchronized Class loadClass(String name, boolean resolve)
-+ throws ClassNotFoundException
-+ {
-+ SecurityManager s = System.getSecurityManager();
-+ if (s != null) {
-+ String cname = name.replace('/', '.');
-+ if (cname.startsWith("[")) {
-+ int b = cname.lastIndexOf('[') + 2;
-+ if (b > 1 && b < cname.length()) {
-+ cname = cname.substring(b);
-+ }
-+ }
-+ int i = cname.lastIndexOf('.');
-+ if (i != -1) {
-+ s.checkPackageAccess(cname.substring(0, i));
-+ }
-+ }
-+ // First, check if the class has already been loaded
-+ Class c = findLoadedClass(name);
-+ if (c == null) {
-+ try {
-+ c = findClass(name);
-+ } catch (ClassNotFoundException e) {
-+ // Fall through ...
-+ }
-+ if (c == null) {
-+ c = getParent().loadClass(name);
-+ }
-+ }
-+ if (resolve) {
-+ resolveClass(c);
-+ }
-+ return c;
-+ }
-+
-+
-+ protected Class findClass(final String name)
-+ throws ClassNotFoundException
-+ {
-+ if (!name.startsWith(JS_PROXY_PKG)) {
-+ throw new ClassNotFoundException(name);
-+ }
-+ String path = name.replace('.', '/').concat(".class");
-+ URL res = getResource(path);
-+ if (res != null) {
-+ try {
-+ return defineClass(name, res);
-+ } catch (IOException e) {
-+ throw new ClassNotFoundException(name, e);
-+ }
-+ } else {
-+ throw new ClassNotFoundException(name);
-+ }
-+ }
-+
-+
-+ /*
-+ * Define the JavaScript proxy classes
-+ */
-+ private Class defineClass(String name, URL url) throws IOException {
-+ byte[] b = getBytes(url);
-+ CodeSource cs = new CodeSource(null, (java.security.cert.Certificate[])null);
-+ if (!name.equals(TRAMPOLINE)) {
-+ throw new IOException("JSClassLoader: bad name " + name);
-+ }
-+ return defineClass(name, b, 0, b.length, cs);
-+ }
-+
-+
-+ /*
-+ * Returns the contents of the specified URL as an array of bytes.
-+ */
-+ private static byte[] getBytes(URL url) throws IOException {
-+ URLConnection uc = url.openConnection();
-+ if (uc instanceof java.net.HttpURLConnection) {
-+ java.net.HttpURLConnection huc = (java.net.HttpURLConnection) uc;
-+ int code = huc.getResponseCode();
-+ if (code >= java.net.HttpURLConnection.HTTP_BAD_REQUEST) {
-+ throw new IOException("open HTTP connection failed.");
-+ }
-+ }
-+ int len = uc.getContentLength();
-+ InputStream in = new BufferedInputStream(uc.getInputStream());
-+
-+ byte[] b;
-+ try {
-+ if (len != -1) {
-+ // Read exactly len bytes from the input stream
-+ b = new byte[len];
-+ while (len > 0) {
-+ int n = in.read(b, b.length - len, len);
-+ if (n == -1) {
-+ throw new IOException("unexpected EOF");
-+ }
-+ len -= n;
-+ }
-+ } else {
-+ b = new byte[8192];
-+ int total = 0;
-+ while ((len = in.read(b, total, b.length - total)) != -1) {
-+ total += len;
-+ if (total >= b.length) {
-+ byte[] tmp = new byte[total * 2];
-+ System.arraycopy(b, 0, tmp, 0, total);
-+ b = tmp;
-+ }
-+ }
-+ // Trim array to correct size, if necessary
-+ if (total != b.length) {
-+ byte[] tmp = new byte[total];
-+ System.arraycopy(b, 0, tmp, 0, total);
-+ b = tmp;
-+ }
-+ }
-+ } finally {
-+ in.close();
-+ }
-+ return b;
-+ }
-+
-+
-+ protected PermissionCollection getPermissions(CodeSource codesource)
-+ {
-+ PermissionCollection perms = super.getPermissions(codesource);
-+ perms.add(new AllPermission());
-+ return perms;
-+ }
-+}
diff --git a/java/jdk15/files/patch-javascript_JSInvoke.java b/java/jdk15/files/patch-javascript_JSInvoke.java
deleted file mode 100644
index fc692b9cb9c1..000000000000
--- a/java/jdk15/files/patch-javascript_JSInvoke.java
+++ /dev/null
@@ -1,26 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSInvoke.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSInvoke.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,21 @@
-+/*
-+ * @(#)JSInvoke.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+
-+package sun.plugin.javascript.invoke;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.InvocationTargetException;
-+
-+/*
-+ * JavaScript to Java invocation trampoline class.
-+ */
-+class JSInvoke {
-+ private static Object invoke(Method m, Object obj, Object[] params)
-+ throws InvocationTargetException, IllegalAccessException {
-+ return m.invoke(obj, params);
-+ }
-+}
diff --git a/java/jdk15/files/patch-javascript_ReflectUtil.java b/java/jdk15/files/patch-javascript_ReflectUtil.java
deleted file mode 100644
index 827bd0c666ce..000000000000
--- a/java/jdk15/files/patch-javascript_ReflectUtil.java
+++ /dev/null
@@ -1,312 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/ReflectUtil.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/ReflectUtil.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,307 @@
-+/*
-+ * @(#)ReflectUtil.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+package sun.plugin.javascript;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Field;
-+import java.lang.reflect.Modifier;
-+import java.lang.reflect.InvocationTargetException;
-+import java.util.HashMap;
-+import java.util.ArrayList;
-+import java.util.List;
-+import java.util.Map;
-+import java.util.Iterator;
-+import sun.plugin.javascript.JSClassLoader;
-+
-+public class ReflectUtil {
-+ /*
-+ * Discover the public methods on public classes
-+ * and interfaces accessible to the calling
-+ * JavaScript code.
-+ */
-+ public static Method[] getJScriptMethods(Class cls) {
-+ List m = new ArrayList(); /* the valid methods we find */
-+
-+ /*
-+ * Temporary map of method signatures when we decide
-+ * that a simple call to target.getMethods() returns
-+ * inaccessible methods and we must search for alternative
-+ * supermethods that might be accessible. We can toss
-+ * this when we're done searching.
-+ */
-+ Map sigs = new HashMap();
-+
-+ while (cls != null) {
-+ boolean done = getPublicMethods(cls, m, sigs);
-+ if (done) {
-+ break;
-+ }
-+ getJScriptInterfaceMethods(cls, m, sigs);
-+ cls = cls.getSuperclass();
-+ }
-+ return (Method[]) m.toArray(new Method[m.size()]);
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ private static void getJScriptInterfaceMethods(Class cls, List m, Map sigs) {
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length; i++) {
-+ Class intf = intfs[i];
-+ boolean done = getPublicMethods(intf, m, sigs);
-+ if (!done) {
-+ getJScriptInterfaceMethods(intf, m, sigs);
-+ }
-+ }
-+ }
-+
-+ /*
-+ *
-+ * Process the methods in this class or interface
-+ */
-+ private static boolean getPublicMethods(Class cls, List m, Map sigs) {
-+ Method[] methods = null;
-+ try {
-+
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's methods. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return false;
-+ }
-+
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return false;
-+ }
-+
-+ methods = cls.getMethods();
-+ } catch (SecurityException se) {
-+ return false;
-+ }
-+
-+ /*
-+ * Check for inherited methods with non-public
-+ * declaring classes. They might override and hide
-+ * methods from their superclasses or
-+ * superinterfaces.
-+ */
-+ boolean done = true;
-+ for (int i=0; i < methods.length; i++) {
-+ Class dc = methods[i].getDeclaringClass();
-+ if (!Modifier.isPublic(dc.getModifiers())) {
-+ done = false;
-+ break;
-+ }
-+ }
-+
-+ /*
-+ * Belatedly initialize the signature map if
-+ * this is not the first time here.
-+ */
-+ if (sigs.isEmpty() && !m.isEmpty()) {
-+ initSignatureMap(m, sigs);
-+ }
-+
-+ if (done) {
-+ /*
-+ * We're done. Spray all the methods into
-+ * the list and then we're out of here.
-+ */
-+ for (int i=0; i < methods.length; i++) {
-+ addMethod(m, sigs, methods[i]);
-+ }
-+ } else {
-+ /*
-+ * Simulate cls.getDeclaredMethods() by
-+ * stripping away inherited methods.
-+ */
-+ for (int i=0; i < methods.length; i++) {
-+ Class dc = methods[i].getDeclaringClass();
-+ if (cls.equals(dc)) {
-+ addMethod(m, sigs, methods[i]);
-+ }
-+ }
-+ }
-+ return done;
-+ }
-+
-+ private static void initSignatureMap(List m, Map sigs) {
-+ Iterator i = m.iterator();
-+ while (i.hasNext()) {
-+ Method entry = (Method) i.next();
-+ sigs.put(getSignature(entry), entry);
-+ }
-+ }
-+
-+ private static void addMethod(List m, Map sigs, Method method) {
-+ /*
-+ * Avoid work. We ignore the signature matching
-+ * until the map is initialized in initSignatureMap.
-+ * This has the effect of avoiding the signature
-+ * work for the first call of getPublicMethods().
-+ */
-+ if (sigs.isEmpty()) {
-+ m.add(method);
-+ return;
-+ }
-+
-+ /*
-+ * Avoid adding duplicate accessible methods on
-+ * the list.
-+ */
-+ String signature = getSignature(method);
-+ if (!sigs.containsKey(signature)) {
-+ m.add(method);
-+ sigs.put(signature, method);
-+ }
-+ }
-+
-+ /*
-+ * Return a canonical method signature for the method.
-+ * We care only about the simple method name and the
-+ * the number, type and order of the parameters.
-+ * Exception declarations are not part of a method
-+ * signature nor is the return type.
-+ */
-+ private static String getSignature(Method method) {
-+ StringBuffer sb = new StringBuffer();
-+
-+ sb.append(method.getName());
-+ Class[] params = method.getParameterTypes();
-+ sb.append('(');
-+ if (params.length > 0) {
-+ sb.append(params[0].getName());
-+ }
-+ for (int i=1; i < params.length; i++) {
-+ sb.append(',');
-+ sb.append(params[i].getName());
-+ }
-+ sb.append(')');
-+
-+ return sb.toString();
-+ }
-+
-+ /*
-+ * Discover the public fields on public classes
-+ * and interfaces accessible to the calling
-+ * JavaScript code.
-+ */
-+ public static Field[] getJScriptFields(Class cls) {
-+ List m = new ArrayList(); /* the valid fields we find */
-+
-+ /*
-+ * Temporary map of field name when we decide
-+ * that a simple call to target.getFields() returns
-+ * inaccessible fields and we must search for alternative
-+ * supermethods that might be accessible. We can toss
-+ * this when we're done searching.
-+ */
-+ Map names = new HashMap();
-+
-+ while (cls != null) {
-+ boolean done = getPublicFields(cls, m, names);
-+ if (done) {
-+ break;
-+ }
-+ getJScriptInterfaceFields(cls, m, names);
-+ cls = cls.getSuperclass();
-+ }
-+ return (Field[]) m.toArray(new Field[m.size()]);
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ private static void getJScriptInterfaceFields(Class cls, List m, Map names) {
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length; i++) {
-+ Class intf = intfs[i];
-+ boolean done = getPublicFields(intf, m, names);
-+ if (!done) {
-+ getJScriptInterfaceFields(intf, m, names);
-+ }
-+ }
-+ }
-+
-+ /*
-+ *
-+ * Process the fields in this class or interface
-+ */
-+ private static boolean getPublicFields(Class cls, List m, Map names) {
-+ Field[] fields = null;
-+ try {
-+
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's fields. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return false;
-+ }
-+
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return false;
-+ }
-+ fields = cls.getFields();
-+ } catch (SecurityException se) {
-+ return false;
-+ }
-+
-+ /*
-+ * Check for inherited fields with non-public
-+ * declaring classes. They might hide
-+ * fields from public classes or interfaces.
-+ */
-+ boolean done = true;
-+ for (int i=0; i < fields.length; i++) {
-+ Class dc = fields[i].getDeclaringClass();
-+ if (!Modifier.isPublic(dc.getModifiers())) {
-+ done = false;
-+ break;
-+ }
-+ }
-+ if (done) {
-+ /*
-+ * We're done. Spray all the fields into
-+ * the list and then we're out of here.
-+ */
-+ for (int i=0; i < fields.length; i++) {
-+ addField(m, names, fields[i]);
-+ }
-+ } else {
-+ /*
-+ * Simulate cls.getDeclaredFields() by
-+ * stripping away inherited fields.
-+ */
-+ for (int i=0; i < fields.length; i++) {
-+ Class dc = fields[i].getDeclaringClass();
-+ if (cls.equals(dc)) {
-+ addField(m, names, fields[i]);
-+ }
-+ }
-+ }
-+ return done;
-+ }
-+
-+ private static void addField(List m, Map names, Field field) {
-+ /*
-+ * Avoid adding duplicate accessible fields on
-+ * the list.
-+ */
-+ String name = field.getName();
-+ if (!names.containsKey(name)) {
-+ m.add(field);
-+ names.put(name, field);
-+ }
-+ }
-+}
-+
-+
diff --git a/java/jdk15/files/patch-liveconnect_ReplaceMethod.java b/java/jdk15/files/patch-liveconnect_ReplaceMethod.java
deleted file mode 100644
index 829e43452e6c..000000000000
--- a/java/jdk15/files/patch-liveconnect_ReplaceMethod.java
+++ /dev/null
@@ -1,93 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/ReplaceMethod.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/ReplaceMethod.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,88 @@
-+/*
-+ * @(#)ReplaceMethod.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+package sun.plugin.liveconnect;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Modifier;
-+import sun.plugin.javascript.JSClassLoader;
-+
-+public class ReplaceMethod {
-+ /*
-+ * Replace the inaccessible method by a suitable method on public
-+ * class/interface accessible to the calling JavaScript code.
-+ * Returns null if accessible method is not found.
-+ */
-+ static Method getJScriptMethod(Method start) {
-+ Class cls = start.getDeclaringClass();
-+
-+ if (Modifier.isPublic(cls.getModifiers())) {
-+ return start;
-+ }
-+
-+ String name = start.getName();
-+ Class[] params = start.getParameterTypes();
-+
-+ Method result = null;
-+ while (cls != null && result == null) {
-+ result = getPublicMethod(cls, name, params);
-+ if (result == null) {
-+ result = getJScriptInterfaceMethod(cls, name, params);
-+ }
-+ cls = cls.getSuperclass();
-+ }
-+ return result;
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ static Method getJScriptInterfaceMethod(Class cls, String name, Class[] params) {
-+ Method result = null;
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length && result == null; i++) {
-+ Class intf = intfs[i];
-+ result = getPublicMethod(intf, name, params);
-+ if (result == null) {
-+ result = getJScriptInterfaceMethod(intf, name, params);
-+ }
-+ }
-+ return result;
-+ }
-+
-+ /*
-+ *
-+ * Process the methods in this class or interface
-+ */
-+ static private Method getPublicMethod(Class cls, String name, Class[] params) {
-+ try {
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's methods. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return null;
-+ }
-+
-+ /*
-+ * This call will fail if 'cls' is in a restricted
-+ * package and we don't have permission to access
-+ * it.
-+ */
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return null;
-+ }
-+ return cls.getMethod(name, params);
-+ } catch (NoSuchMethodException nsme) {
-+ return null;
-+ } catch (SecurityException se) {
-+ return null;
-+ }
-+ }
-+}
-+
-+
diff --git a/java/jdk15/files/patch-liveconnect_SecureInvocation.java b/java/jdk15/files/patch-liveconnect_SecureInvocation.java
deleted file mode 100644
index 961414277909..000000000000
--- a/java/jdk15/files/patch-liveconnect_SecureInvocation.java
+++ /dev/null
@@ -1,351 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/SecureInvocation.java 22 Oct 2003 23:04:21 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/SecureInvocation.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
- * @(#)SecureInvocation.java 1.21 02/08/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,7 +9,8 @@
-
- import java.lang.reflect.Constructor;
- import java.lang.reflect.Field;
--import java.lang.reflect.Method;
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Modifier;
- import java.lang.Thread;
- import java.io.FilePermission;
- import java.security.AccessControlContext;
-@@ -29,7 +30,10 @@
- import java.net.URL;
- import java.net.MalformedURLException;
- import sun.plugin.util.Trace;
--import sun.plugin.services.PlatformService;
-+import sun.plugin.services.PlatformService;
-+import sun.plugin.javascript.JSClassLoader;
-+import sun.plugin.javascript.ReflectUtil;
-+
-
- /**
- * <P> SecureInvocation is for implementating nsISecureJNI which allows
-@@ -98,64 +102,64 @@
- throw e;
- }
- }
--
-- static class CallMethodThread extends Thread {
-- public CallMethodThread(int handle, Class clazz, Object obj, Method method, Object[] args,
-- String origin, boolean isUniversalBrowserRead,
-- boolean isUniversalJavaPermission) {
-- this.handle = handle;
-- this.clazz = clazz;
-- this.obj = obj;
-- this.method = method;
-- this.args = args;
-- this.origin = origin;
-- this.isUniversalBrowserRead = isUniversalBrowserRead;
-- this.isUniversalJavaPermission = isUniversalJavaPermission;
-- }
--
-- public void run() {
-- try {
-- result = CallMethod(clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-- }
-- catch(Exception e) {
-- exception = e;
-- }
-- finally {
-- PlatformService.getService().signalEvent(handle);
-- }
-- }
--
--
-- public Object getResult() throws Exception {
-- if(exception != null)
-- throw exception;
-- return result;
-- }
--
-- private Exception exception = null;
-- private Object result = null;
--
-- private int handle;
-- private Class clazz;
-- private Object obj;
-- private Method method;
-- private Object[] args;
-- private String origin;
-- private boolean isUniversalBrowserRead;
-- private boolean isUniversalJavaPermission;
--
-- }
--
-- public static Object CallMethod(final int handle, final Class clazz, final Object obj, final Method method, final Object[] args,
-- final String origin, final boolean isUniversalBrowserRead,
-- final boolean isUniversalJavaPermission)
-- throws Exception {
-- CallMethodThread callThread = new CallMethodThread(handle, clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-- callThread.start();
-- PlatformService.getService().waitEvent(handle);
-- return callThread.getResult();
-- }
--
-+
-+ static class CallMethodThread extends Thread {
-+ public CallMethodThread(int handle, Class clazz, Object obj, Method method, Object[] args,
-+ String origin, boolean isUniversalBrowserRead,
-+ boolean isUniversalJavaPermission) {
-+ this.handle = handle;
-+ this.clazz = clazz;
-+ this.obj = obj;
-+ this.method = method;
-+ this.args = args;
-+ this.origin = origin;
-+ this.isUniversalBrowserRead = isUniversalBrowserRead;
-+ this.isUniversalJavaPermission = isUniversalJavaPermission;
-+ }
-+
-+ public void run() {
-+ try {
-+ result = CallMethod(clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-+ }
-+ catch(Exception e) {
-+ exception = e;
-+ }
-+ finally {
-+ PlatformService.getService().signalEvent(handle);
-+ }
-+ }
-+
-+
-+ public Object getResult() throws Exception {
-+ if(exception != null)
-+ throw exception;
-+ return result;
-+ }
-+
-+ private Exception exception = null;
-+ private Object result = null;
-+
-+ private int handle;
-+ private Class clazz;
-+ private Object obj;
-+ private Method method;
-+ private Object[] args;
-+ private String origin;
-+ private boolean isUniversalBrowserRead;
-+ private boolean isUniversalJavaPermission;
-+
-+ }
-+
-+ public static Object CallMethod(final int handle, final Class clazz, final Object obj, final Method method, final Object[] args,
-+ final String origin, final boolean isUniversalBrowserRead,
-+ final boolean isUniversalJavaPermission)
-+ throws Exception {
-+ CallMethodThread callThread = new CallMethodThread(handle, clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-+ callThread.start();
-+ PlatformService.getService().waitEvent(handle);
-+ return callThread.getResult();
-+ }
-+
-
- /**
- * <P> Call a method on Java object with security context.
-@@ -197,8 +201,8 @@
- AccessControlContext context = new AccessControlContext(domains);
-
- // Perform the method invocation.
-- return AccessController.doPrivileged(new PrivilegedCallMethodAction(method, obj, args),
-- context);
-+ return AccessController.doPrivileged(new PrivilegedCallMethodAction(method,
-+ obj, args), context);
- } catch (Exception e) {
- Trace.liveConnectPrintException(e);
- throw e;
-@@ -323,32 +327,6 @@
- }
- }
-
--
-- /**
-- * <P> Set up a protection domain according to the origin and
-- * the other security related information.
-- */
-- private static ProtectionDomain getProtectionDomain(Class clazz,
-- String origin,
-- boolean byPassOrigin,
-- boolean allPermission)
-- throws OriginNotAllowedException, MalformedURLException
-- {
-- boolean trust = false;
--
-- // First, check if the call is allowed
-- checkLiveConnectCaller(clazz, origin, byPassOrigin);
--
-- if (allPermission)
-- {
-- return getTrustedProtectionDomain();
-- }
-- else
-- {
-- return getDefaultProtectionDomain(origin);
-- }
-- }
--
- /**
- * <P> Check if LiveConnect call is allowed at all.
- * </P>
-@@ -447,7 +425,7 @@
-
- // Obtain Java policy
- Policy policy = Policy.getPolicy();
-- CodeSource cs = new CodeSource(url, null);
-+ CodeSource cs = new CodeSource(url, (java.security.cert.Certificate[])null);
- final PermissionCollection pc = policy.getPermissions(cs);
-
- if (url == null || url.getProtocol().equals("file")) {
-@@ -516,16 +494,19 @@
-
- PrivilegedConstructObjectAction(Constructor constructor, Object[] args)
- {
-- this.constructor = constructor;
-- this.args = args;
-+ this.constructor = constructor;
-+ this.args = args;
-
-- // Ensure the argument is not null
-- if (this.args == null)
-- this.args = new Object[0];
-+ // Ensure the argument is not null
-+ if (this.args == null)
-+ this.args = new Object[0];
- }
-
- public Object run() throws Exception {
-- return constructor.newInstance(args);
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(constructor.getDeclaringClass());
-+
-+ return constructor.newInstance(args);
- }
- }
-
-@@ -543,17 +524,54 @@
-
- PrivilegedCallMethodAction(Method method, Object obj, Object[] args)
- {
-- this.method = method;
-- this.obj = obj;
-- this.args = args;
--
-- // Ensure the argument is not null
-- if (this.args == null)
-- this.args = new Object[0];
-+ this.method = method;
-+
-+ this.obj = obj;
-+ this.args = args;
-+
-+ // Ensure the argument is not null
-+ if (this.args == null)
-+ this.args = new Object[0];
- }
-
- public Object run() throws Exception {
-- return method.invoke(obj, args);
-+ /*
-+ * Browser uses reflection to collect methods/fields/constructors
-+ * through this method call. Therefore JSClassLoader is not used
-+ * in such cases. However it requires filtering to avoid exposing
-+ * inaccessible methods/fields/constructors.
-+ *
-+ * Also, Mozilla ignores abstract methods, therefore those are
-+ * replaced by the concrete class methods
-+ */
-+ if(obj instanceof Class) {
-+ String name = method.getName();
-+ Class cls = (Class)obj;
-+ if(name.equals("getMethods")) {
-+ Method[] methods = ReflectUtil.getJScriptMethods(cls);
-+ for (int i=0; i < methods.length; i++) {
-+ Method m = methods[i];
-+ if (Modifier.isAbstract(m.getModifiers())) {
-+ Class[] params = m.getParameterTypes();
-+ methods[i] = cls.getMethod(m.getName(), params);
-+ }
-+ }
-+ return methods;
-+ }else if (name.equals("getFields")) {
-+ return ReflectUtil.getJScriptFields(cls);
-+ }else if (name.equals("getConstructors")) {
-+ if (!Modifier.isPublic(cls.getModifiers()) ||
-+ !JSClassLoader.isPackageAccessible(cls)) {
-+ return new Constructor[0];
-+ }
-+ }
-+ }
-+
-+ Method actualMethod = ReplaceMethod.getJScriptMethod(method);
-+ if(actualMethod != null)
-+ return JSClassLoader.invoke(actualMethod, obj, args);
-+ else
-+ throw new NoSuchMethodException(method.getName());
- }
- }
-
-@@ -564,18 +582,20 @@
- * </P>
- */
- class PrivilegedGetFieldAction implements PrivilegedExceptionAction {
--
- Field field;
- Object obj;
-
- PrivilegedGetFieldAction(Field field, Object obj)
- {
-- this.field = field;
-- this.obj = obj;
-+ this.field = field;
-+ this.obj = obj;
- }
-
-- public Object run() throws Exception {
-- return field.get(obj);
-+ public Object run() throws Exception {
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(field.getDeclaringClass());
-+
-+ return field.get(obj);
- }
- }
-
-@@ -593,15 +613,18 @@
-
- PrivilegedSetFieldAction(Field field, Object obj, Object val)
- {
-- this.field = field;
-- this.obj = obj;
-- this.val = val;
-+ this.field = field;
-+ this.obj = obj;
-+ this.val = val;
- }
-
- public Object run() throws Exception {
-- field.set(obj, val);
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(field.getDeclaringClass());
-+
-+ field.set(obj, val);
- return null;
- }
- }
--
--
-+
-+
diff --git a/java/jdk15/files/patch-native::util.c b/java/jdk15/files/patch-native::util.c
deleted file mode 100644
index 719d1ae0e989..000000000000
--- a/java/jdk15/files/patch-native::util.c
+++ /dev/null
@@ -1,16 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/javaws/src/share/native/util.c 22 Oct 2003 23:04:17 -0000 1.1.1.1
-+++ ../../deploy/src/javaws/src/share/native/util.c 16 Jan 2004 23:50:11 -0000
-@@ -27,7 +27,10 @@
-
- /* Find size of file */
- struct stat statBuf;
-- stat(filename, &statBuf);
-+ if (stat(filename, &statBuf) == -1) {
-+ *buffer = NULL;
-+ return 0;
-+ }
- size = statBuf.st_size;
-
- /* Allocate memory for contents */
diff --git a/java/jdk15/files/patch-nspr_pth.h b/java/jdk15/files/patch-nspr_pth.h
deleted file mode 100644
index c2a1cb5d5ed1..000000000000
--- a/java/jdk15/files/patch-nspr_pth.h
+++ /dev/null
@@ -1,11 +0,0 @@
---- ../../deploy/src/plugin/oji-plugin/include/solaris/navig4/nspr/md/_pth.h 22 Oct 2003 23:04:19 -0000 1.1.1.1
-+++ ../../deploy/src/plugin/oji-plugin/include/solaris/navig4/nspr/md/_pth.h 21 Oct 2004 05:47:13 -0000
-@@ -52,7 +52,7 @@
- #define PTHREAD_MUTEXATTR_INIT pthread_mutexattr_init
- #define PTHREAD_MUTEXATTR_DESTROY pthread_mutexattr_destroy
- #define PTHREAD_MUTEX_INIT(m, a) pthread_mutex_init(&(m), &(a))
--#define PTHREAD_MUTEX_IS_LOCKED(m) (EBUSY == pthread_mutex_trylock(&(m)))
-+#define PTHREAD_MUTEX_IS_LOCKED(m) (0 != pthread_mutex_trylock(&(m)))
- #define PTHREAD_CONDATTR_INIT pthread_condattr_init
- #define PTHREAD_CONDATTR_DESTROY pthread_condattr_destroy
- #define PTHREAD_COND_INIT(m, a) pthread_cond_init(&(m), &(a))
diff --git a/java/jdk15/files/patch-plugin_DispatchImpl.java b/java/jdk15/files/patch-plugin_DispatchImpl.java
deleted file mode 100644
index abb65a60953e..000000000000
--- a/java/jdk15/files/patch-plugin_DispatchImpl.java
+++ /dev/null
@@ -1,331 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/com/DispatchImpl.java 22 Oct 2003 23:04:20 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/com/DispatchImpl.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
-- * @(#)DispatchImpl.java 1.6 03/01/23
-+ * @(#)DispatchImpl.java 1.16 04/06/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,8 +9,32 @@
-
- import sun.plugin.util.Trace;
- import sun.plugin.javascript.ocx.JSObject;
--import java.applet.Applet;
-+import sun.plugin.liveconnect.JavaScriptProtectionDomain;
- import sun.plugin.viewer.context.IExplorerAppletContext;
-+import sun.plugin.security.PluginClassLoader;
-+import java.applet.Applet;
-+import java.net.URL;
-+import java.net.MalformedURLException;
-+import java.net.InetAddress;
-+import java.net.UnknownHostException;
-+import java.net.SocketPermission;
-+import java.io.FilePermission;
-+import java.io.File;
-+import java.security.AccessControlContext;
-+import java.security.AccessController;
-+import java.security.CodeSource;
-+import java.security.Policy;
-+import java.security.ProtectionDomain;
-+import java.security.AllPermission;
-+import java.security.Permissions;
-+import java.security.Permission;
-+import java.security.PermissionCollection;
-+import java.security.PrivilegedAction;
-+import java.security.PrivilegedExceptionAction;
-+import java.security.AccessControlException;
-+import java.security.PrivilegedActionException;
-+import sun.net.www.ParseUtil;
-+import sun.security.util.SecurityConstants;
-
- /**
- * DispatchImpl encapsulates a Java Object and provides Dispatch interface
-@@ -22,14 +46,19 @@
- {
- JavaClass targetClass = null;
- Object targetObj = null;
-+ int handle = 0;
-+ int wndHandle = 0;
-+ AccessControlContext context = null;
-+ boolean isBridge = false;
-
- /*
- * Constructor
- * @param obj the object to be wrapped
- */
-- public DispatchImpl(Object obj)
-+ public DispatchImpl(Object obj, int id)
- {
- targetObj = obj;
-+ handle = id;
- }
-
- /**
-@@ -40,19 +69,87 @@
- * @param params Arguments.
- * @return Java object.
- */
-- public Object invoke(int flag, int index, Object []params)
-+ public Object invoke(final int flag, final int index, final Object []params)
-+ throws Exception
-+ {
-+ try {
-+ //No security constraints in case of ActiveX bridge application
-+ if(isBridge)
-+ return invokeImpl(flag, index, params);
-+
-+ if(context == null) {
-+ context = createContext();
-+ }
-+
-+ // Invoke the method within the applet sand box security restricitions
-+ return AccessController.doPrivileged(
-+ new PrivilegedExceptionAction() {
-+ public Object run() throws Exception{
-+ return invokeImpl(flag, index, params);
-+ }
-+ }, context
-+ );
-+ }catch(Exception exc) {
-+ Throwable cause = exc.getCause();
-+ if(cause == null) {
-+ cause = exc;
-+ }
-+
-+ Trace.liveConnectPrintException(cause);
-+ throw new Exception(cause.toString());
-+ }
-+ }
-+
-+ public AccessControlContext createContext() {
-+ try {
-+ ProtectionDomain[] domains = new ProtectionDomain[1];
-+ //Obtain the java code origin
-+ ProtectionDomain pd = (ProtectionDomain)AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ return targetObj.getClass().getProtectionDomain();
-+ }
-+ });
-+
-+ CodeSource cs = null;
-+ URL url = null;
-+ if(pd != null)
-+ cs = pd.getCodeSource();
-+ if(cs != null)
-+ url = cs.getLocation();
-+
-+ domains[0] = getJSProtectionDomain(url, targetObj.getClass());
-+ return new AccessControlContext(domains);
-+ }catch(Exception exc) {
-+ Trace.liveConnectPrintException(exc);
-+ }
-+
-+ return null;
-+ }
-+
-+ /**
-+ * Invoke a method according to the method index.
-+ *
-+ * @param flag Invoke flag
-+ * @param index Method index
-+ * @param params Arguments.
-+ * @return Java object.
-+ */
-+ public Object invokeImpl(int flag, int index, Object []params)
- throws Exception
- {
- Object retObj = null;
- Dispatcher disp = null;
- try {
-- convertParams(params);
-+ if(params != null)
-+ convertParams(params);
- disp = targetClass.getDispatcher(flag, index, params);
-- return disp.invoke(targetObj, params);
-- }
-- catch (Throwable e)
-- {
-- //e.printStackTrace();
-+ if(disp != null) {
-+ retObj = disp.invoke(targetObj, params);
-+ if(retObj != null)
-+ retObj = Utils.convertReturn(disp.getReturnType(), retObj, handle);
-+ }
-+ return retObj;
-+ } catch (Throwable e) {
- Throwable cause = e.getCause();
- if(cause == null) {
- cause = e;
-@@ -82,11 +179,39 @@
- return targetClass;
- }
-
-+ public int getReturnType(int id){
-+ return targetClass.getReturnType(id);
-+ }
-+
-+ public int getIdForName(final String name) throws Exception{
-+ try {
-+ //No security constraints in case of ActiveX bridge application
-+ if(isBridge)
-+ return getIdForNameImpl(name);
-+
-+ if(context == null) {
-+ context = createContext();
-+ }
-+
-+ // Invoke the method within the applet sand box security restricitions
-+ Integer retVal = (Integer)AccessController.doPrivileged(
-+ new PrivilegedExceptionAction() {
-+ public Object run() throws Exception{
-+ return new Integer(getIdForNameImpl(name));
-+ }
-+ }, context
-+ );
-+ return retVal.intValue();
-+ }catch(PrivilegedActionException pe) {
-+ }
-+
-+ return -1;
-+ }
-
- /*
- *
- */
-- public int getIdForName(String name) throws Exception{
-+ public int getIdForNameImpl(String name) throws Exception{
- int id = -1;
-
- if(targetClass == null && targetObj != null) {
-@@ -103,27 +228,122 @@
- }
-
- /*
-- *
-+ * Unwraps the wrapped java object arguments
- */
- private void convertParams(Object []params) {
- for(int i=0;i<params.length;i++) {
- if(params[i] != null && params[i] instanceof DispatchImpl) {
- params[i] = ((DispatchImpl)params[i]).getWrappedObject();
- } else if(params[i] != null && params[i] instanceof DispatchClient){
-- JSObject jsObj = new JSObject((DispatchClient)params[i]);
-- jsObj.setIExplorerAppletContext((IExplorerAppletContext)
-+ JSObject jsObj = null;
-+ if (!isBridge) {
-+ jsObj = new JSObject((DispatchClient)params[i]);
-+ jsObj.setIExplorerAppletContext((IExplorerAppletContext)
- ((Applet)targetObj).getAppletContext());
-+ } else {
-+ jsObj = new JSObject((DispatchClient)params[i], handle);
-+ }
- params[i] = jsObj;
- }
- }
- }
-
-+ /**
-+ * Returns a protection domain that represents the default permission
-+ * for a given URL.
-+ *
-+ * @param urlString URL
-+ * @return protection domain.
-+ */
-+ public static ProtectionDomain getJSProtectionDomain(URL url, Class clazz)
-+ throws MalformedURLException {
-+
-+ // Obtain default java applet policy
-+ Policy policy = (Policy)AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ return Policy.getPolicy();
-+ }
-+ });
-+
-+ CodeSource cs = new CodeSource(null, (java.security.cert.Certificate[])null);
-+ final PermissionCollection pc = policy.getPermissions(cs);
-+ if(url != null) {
-+ Permission p;
-+ String path = null;
-+ try {
-+ p = url.openConnection().getPermission();
-+ } catch (java.io.IOException ioe) {
-+ p = null;
-+ }
-+
-+ if (p instanceof FilePermission) {
-+ path = p.getName();
-+ } else if ((p == null) && (url.getProtocol().equals("file"))) {
-+ path = url.getFile().replace('/', File.separatorChar);
-+ path = ParseUtil.decode(path);
-+ } else if (p instanceof SocketPermission) {
-+ /*
-+ Socket permission to connect back to the host
-+ */
-+ String host = url.getHost();
-+ pc.add(new SocketPermission(host,
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ }
-+
-+ if(path != null &&
-+ (clazz.getClassLoader() instanceof PluginClassLoader)) {
-+ //We need to add an additional permission to read recursively
-+ if (path.endsWith(File.separator)) {
-+ path += "-";
-+ } else {
-+ int endIndex = path.lastIndexOf(File.separatorChar);
-+ if (endIndex != -1)
-+ path = path.substring(0, endIndex+1) + "-";
-+ }
-+
-+ pc.add(new FilePermission(path, SecurityConstants.FILE_READ_ACTION));
-+
-+ /*
-+ Socket permission to connect back to the "localhost"
-+ */
-+ pc.add(new SocketPermission("localhost",
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ try {
-+ String host = InetAddress.getLocalHost().getHostName();
-+ pc.add(new SocketPermission(host,
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ } catch (UnknownHostException uhe) {
-+ }
-+ return null;
-+ }
-+ });
-+ }
-+ }
-+
-+ return new JavaScriptProtectionDomain(pc);
-+ }
-+
- public String toString() {
- if(targetObj != null) {
- return targetObj.toString();
- }
- return null;
- }
-+
-+ public int getWindowHandle() {
-+ if(wndHandle == 0) {
-+ wndHandle = getWindowHandle(handle);
-+ }
-+ return wndHandle;
-+ }
-+
-+ protected void setBridge() {
-+ isBridge = true;
-+ }
-+
-+ native int getWindowHandle(int id);
- }
-
-
diff --git a/java/jdk15/files/patch-plugin_FileList.gmk b/java/jdk15/files/patch-plugin_FileList.gmk
deleted file mode 100644
index c5fca27bdda9..000000000000
--- a/java/jdk15/files/patch-plugin_FileList.gmk
+++ /dev/null
@@ -1,22 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/make/plugin/java/FileList.gmk 7 Nov 2003 12:15:52 -0000 1.2
-+++ ../../deploy/make/plugin/java/FileList.gmk 3 Dec 2004 03:56:58 -0000 1.3
-@@ -86,6 +86,9 @@
- \
- sun/plugin/javascript/JSObject.java \
- sun/plugin/javascript/JSContext.java \
-+ sun/plugin/javascript/JSClassLoader.java \
-+ sun/plugin/javascript/ReflectUtil.java \
-+ sun/plugin/javascript/JSInvoke.java \
- \
- sun/plugin/javascript/navig/Navigator.java \
- sun/plugin/javascript/navig/Document.java \
-@@ -125,6 +128,7 @@
- sun/plugin/liveconnect/JavaScriptPermission.java \
- sun/plugin/liveconnect/SecurityContextHelper.java \
- sun/plugin/liveconnect/LiveConnect.java \
-+ sun/plugin/liveconnect/ReplaceMethod.java \
- \
- sun/plugin/extension/ExtensionInstallationImpl.java \
- sun/plugin/extension/ExtensionInstaller.java \
diff --git a/java/jdk15/files/patch-plugin_MethodDispatcher.java b/java/jdk15/files/patch-plugin_MethodDispatcher.java
deleted file mode 100644
index 57e6d22b5a63..000000000000
--- a/java/jdk15/files/patch-plugin_MethodDispatcher.java
+++ /dev/null
@@ -1,41 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/com/MethodDispatcher.java 22 Oct 2003 23:04:20 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/com/MethodDispatcher.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
-- * @(#)MethodDispatcher.java 1.5 03/01/23
-+ * @(#)MethodDispatcher.java 1.10 04/06/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,6 +9,7 @@
-
- import java.lang.reflect.Method;
- import sun.plugin.util.Trace;
-+import sun.plugin.javascript.JSClassLoader;
-
- /**
- * A <code>MethodDispatcher</code> provides information about,
-@@ -47,11 +48,16 @@
- Object retObj = null;
- if(method != null && obj != null) {
- Trace.msgLiveConnectPrintln("com.method.invoke", new Object[] {method});
-+ Class theClass = obj.getClass();
- Object[] params = TypeConverter.convertObjectArray(
- method.getParameterTypes(), args);
-- retObj = Utils.convertReturn( method.getReturnType(),
-- method.invoke(obj, params ));
-+ // check if the class is private and the method is public
-+ retObj = JSClassLoader.invoke(method, obj, params);
- }
- return retObj;
-+ }
-+
-+ public Class getReturnType() {
-+ return method.getReturnType();
- }
- }
diff --git a/java/jdk15/files/patch-plugin_ns600_nscore.h b/java/jdk15/files/patch-plugin_ns600_nscore.h
deleted file mode 100644
index 9e4bcacf650a..000000000000
--- a/java/jdk15/files/patch-plugin_ns600_nscore.h
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns600/nscore.h.orig Fri Jul 30 18:00:04 2004
-+++ ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns600/nscore.h Fri Jul 30 23:32:31 2004
-@@ -163,7 +163,7 @@
- */
-
- /* under Metrowerks (Mac), we don't have autoconf yet */
--#ifdef __MWERKS__
-+#if defined(__MWERKS__) || defined(NS_UNIX)
- #define HAVE_CPP_SPECIALIZATION
- #define HAVE_CPP_PARTIAL_SPECIALIZATION
- #define HAVE_CPP_MODERN_SPECIALIZE_TEMPLATE_SYNTAX
diff --git a/java/jdk15/files/patch-plugin_ns610_nscore.h b/java/jdk15/files/patch-plugin_ns610_nscore.h
deleted file mode 100644
index de8cc76e5fa3..000000000000
--- a/java/jdk15/files/patch-plugin_ns610_nscore.h
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns610/nscore.h.orig Fri Jul 30 18:00:05 2004
-+++ ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns610/nscore.h Fri Jul 30 23:23:36 2004
-@@ -163,7 +163,7 @@
- */
-
- /* under Metrowerks (Mac), we don't have autoconf yet */
--#ifdef __MWERKS__
-+#if defined(__MWERKS__) || defined(NS_UNIX)
- #define HAVE_CPP_SPECIALIZATION
- #define HAVE_CPP_PARTIAL_SPECIALIZATION
- #define HAVE_CPP_MODERN_SPECIALIZE_TEMPLATE_SYNTAX
diff --git a/java/jdk15/files/patch-vm::os_bsd.hpp b/java/jdk15/files/patch-vm::os_bsd.hpp
deleted file mode 100644
index cab94f46e4d3..000000000000
--- a/java/jdk15/files/patch-vm::os_bsd.hpp
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/os/bsd/vm/os_bsd.hpp.orig Wed Oct 20 16:01:08 2004
-+++ ../../hotspot/src/os/bsd/vm/os_bsd.hpp Wed Oct 20 16:01:30 2004
-@@ -353,7 +353,7 @@
- bool trylock() {
- verify();
- int status = pthread_mutex_trylock(_mutex);
-- if (status == EBUSY)
-+ if (status == EBUSY || status == EDEADLK)
- return false;
- assert(status == 0, "pthread_mutex_trylock");
- #ifndef PRODUCT
diff --git a/java/jdk15/pkg-plist b/java/jdk15/pkg-plist
index 32bbfdbb4198..901429fa23fb 100644
--- a/java/jdk15/pkg-plist
+++ b/java/jdk15/pkg-plist
@@ -893,6 +893,7 @@ jdk%%JDK_VERSION%%/jre/Welcome.html
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/bin/ControlPanel
jdk%%JDK_VERSION%%/jre/bin/java
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/bin/java_vm
+%%MINIMAL:%%%%DEBUG:%%jdk%%JDK_VERSION%%/jre/bin/java_vm_g
jdk%%JDK_VERSION%%/jre/bin/keytool
jdk%%JDK_VERSION%%/jre/bin/kinit
jdk%%JDK_VERSION%%/jre/bin/klist
@@ -980,6 +981,7 @@ jdk%%JDK_VERSION%%/jre/lib/i386/libioser12.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjaas_unix.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjava.so
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/lib/i386/libjavaplugin_jni.so
+%%MINIMAL:%%%%DEBUG:%%jdk%%JDK_VERSION%%/jre/lib/i386/libjavaplugin_jni_g.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjawt.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjcov.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjdwp.so
diff --git a/java/jdk16/Makefile b/java/jdk16/Makefile
index 169a67f7b96d..31744bfcb4b1 100644
--- a/java/jdk16/Makefile
+++ b/java/jdk16/Makefile
@@ -7,7 +7,6 @@
PORTNAME= jdk
PORTVERSION= ${JDK_VERSION}p${JDK_PATCHSET_VERSION}
-PORTREVISION= 7
CATEGORIES= java devel
MASTER_SITES= # http://www.sun.com/software/java2/download.html
# http://www.eyesbeyond.com/freebsddom/java/jdk14.html
@@ -32,7 +31,7 @@ RUN_DEPENDS+= ${X11BASE}/lib/X11/fonts/URW/fonts.dir:${PORTSDIR}/x11-fonts/urwfo
WRKSRC= ${WRKDIR}/control/make
JDK_VERSION= 1.4.2
-JDK_PATCHSET_VERSION= 6
+JDK_PATCHSET_VERSION= 7
LATEST_LINK= jdk14
SUN_LINUX_JDK_VERSION= 1.4.2
@@ -315,6 +314,9 @@ do-install:
.endif
post-install:
+.if !defined(MINIMAL)
+ ${FIND} "${PREFIX}/jdk${JDK_VERSION}/jre/plugin" -type d | ${XARGS} ${CHMOD} a+rx
+.endif
@${LOCALBASE}/bin/registervm "${PREFIX}/jdk${JDK_VERSION}/bin/java # FREEBSD-JDK${JDK_VERSION}"
@${SED} -e "s:%%JRE_HOME%%:${PREFIX}/jdk${JDK_VERSION}/jre:g" \
< ${FILESDIR}/pkg-install.in > ${PKGINSTALL}
diff --git a/java/jdk16/distinfo b/java/jdk16/distinfo
index 9fb0a0721197..fb62f1cbad29 100644
--- a/java/jdk16/distinfo
+++ b/java/jdk16/distinfo
@@ -2,5 +2,5 @@ MD5 (j2sdk-1_4_2-src-scsl.zip) = 387ae674dcd686f3a7a477c191aa8b65
SIZE (j2sdk-1_4_2-src-scsl.zip) = 49269919
MD5 (j2sdk-1_4_2-bin-scsl.zip) = 24877ff50ae66744090c3723968bb7dc
SIZE (j2sdk-1_4_2-bin-scsl.zip) = 2513462
-MD5 (bsd-jdk14-patches-6.tar.gz) = fe01a66ce4e8425f169c1b4a88d08f87
-SIZE (bsd-jdk14-patches-6.tar.gz) = 1068798
+MD5 (bsd-jdk14-patches-7.tar.gz) = fe76afc2dd8651350a2f0e221d928fa5
+SIZE (bsd-jdk14-patches-7.tar.gz) = 1137785
diff --git a/java/jdk16/files/patch-awt_Component.c b/java/jdk16/files/patch-awt_Component.c
deleted file mode 100644
index db768c611349..000000000000
--- a/java/jdk16/files/patch-awt_Component.c
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/solaris/native/sun/awt/awt_Component.c.orig 27 Oct 2003 12:16:41 -0000 1.4
-+++ ../../j2se/src/solaris/native/sun/awt/awt_Component.c 1 Mar 2004 21:36:45 -0000 1.5
-@@ -1179,7 +1179,7 @@
- }
- XtVaSetValues(to, XmNtraversalOn, True, NULL);
- }
-- } else if (from != NULL) {
-+ } else if (from != NULL && to != NULL) {
- // disable the tree starting from uncommon part to 'from'
- if (parents_from[index] == parents_to[index]) {
- if (index == count_from - 1) {
diff --git a/java/jdk16/files/patch-awt_fontmanager_fontObject.cpp b/java/jdk16/files/patch-awt_fontmanager_fontObject.cpp
deleted file mode 100644
index 3efc10e85b68..000000000000
--- a/java/jdk16/files/patch-awt_fontmanager_fontObject.cpp
+++ /dev/null
@@ -1,53 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/fontObject.cpp.orig Wed Jul 7 09:33:52 2004
-+++ ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/fontObject.cpp Wed Jul 7 13:26:03 2004
-@@ -416,7 +416,11 @@
- fUseCount += 1;
-
- if (length > 0 && fFileSize > 0) {
-- assert(offset < fFileSize);
-+ if (offset >= fFileSize) {
-+ fUseCount--;
-+ return NULL;
-+ }
-+
- if ((offset + length) > fFileSize)
- length = fFileSize - offset;
-
-@@ -431,13 +435,14 @@
- "fileFontObject::ReadChunk(UInt32,UInt32,void*)\n"
- );
- #endif
-+ fUseCount--;
- return NULL;
- }
-
- off_t err = lseek(fFile, offset, SEEK_SET);
- #ifdef DEBUG
- if (err == (off_t)-1) {
-- fprintf(stderr, "seek(%d) returned %d\n", offset, (int) err);
-+ fprintf(stderr, "seek(%ld) returned %d\n", offset, (int) err);
- }
- #endif
-
-@@ -448,7 +453,7 @@
- int tellvalue = lseek(fFile, 0, SEEK_END);
- #ifdef DEBUG
- fprintf(stderr,
-- "<%s> of %d, ln %d, rd %d, sz %d, tell %d, err %d\n",
-+ "<%s> of %ld, ln %ld, rd %d, sz %ld, tell %d, err %d\n",
- (char *)fFileName, offset, length, (int)bytesRead,
- fFileSize, tellvalue, (int) err);
- #endif
-@@ -1457,7 +1462,9 @@
- return false;
- }
-
-- this->ReadChunk(sizeof theHeader, fFontCount * sizeof *offsets, offsets);
-+ if (this->ReadChunk(sizeof theHeader, fFontCount * sizeof *offsets, offsets) == NULL) {
-+ return false;
-+ }
- for (int i=0; i<fFontCount; i++) {
- offsets[i] = GET32(offsets[i]);
- }
diff --git a/java/jdk16/files/patch-awt_fontmanager_t2kScalerContext.cpp b/java/jdk16/files/patch-awt_fontmanager_t2kScalerContext.cpp
deleted file mode 100644
index 7f39f7cceabb..000000000000
--- a/java/jdk16/files/patch-awt_fontmanager_t2kScalerContext.cpp
+++ /dev/null
@@ -1,21 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/t2kScalerContext.cpp.orig Fri Jul 30 18:00:09 2004
-+++ ../../j2se/src/share/native/sun/awt/font/fontmanager/fontobjects/t2kScalerContext.cpp Fri Jul 30 22:11:36 2004
-@@ -937,14 +937,14 @@
- CMAPMapper::CharsToGlyphs(
- int count, const Unicode16 unicodes[], UInt32 glyphs[]) const
- {
-- ConvertUnicodeToGlyphs(*font, (unsigned char *)cmap, count, unicodes, glyphs);
-+ ConvertUnicodeToGlyphs(*font, (byte*&)cmap, count, unicodes, glyphs);
- }
-
- void
- CMAPMapper::CharsToGlyphs(
- int count, const Unicode32 unicodes[], UInt32 glyphs[]) const
- {
-- ConvertUnicodeToGlyphs(*font, (unsigned char *)cmap, count, unicodes, glyphs);
-+ ConvertUnicodeToGlyphs(*font, (byte*&)cmap, count, unicodes, glyphs);
- }
-
- //////////////////////////////////////////////////////////////////////////////
diff --git a/java/jdk16/files/patch-deploy::Makefile b/java/jdk16/files/patch-deploy::Makefile
deleted file mode 100644
index a34bfa0c9d71..000000000000
--- a/java/jdk16/files/patch-deploy::Makefile
+++ /dev/null
@@ -1,46 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/make/Makefile.orig Tue Jan 27 18:54:56 2004
-+++ ../../deploy/make/Makefile Tue Jan 27 18:58:08 2004
-@@ -24,17 +24,29 @@
- DEPLOY_TOPDIR=..
- include $(BUILDDIR)/common/Defs.gmk
-
-+ifdef NO_PLUGIN
-+BUILD_PLUGIN= false
-+else
-+BUILD_PLUGIN= true
-+endif
-+
-+ifdef NO_JAVAWS
-+BUILD_JAVAWS= false
-+else
-+BUILD_JAVAWS= true
-+endif
-+
- all::
- @$(ECHO) "$(PLATFORM) $(ARCH) $(RELEASE) deploy build started: $(shell $(DATE) '+%y-%m-%d %H:%M')"
-
--BUILD_PLUGIN = true
--
- #
- # Core.
- #
- JAVAWS_SUBDIR = javaws
- PLUGIN_SUBDIR = plugin
-+ifeq ($(BUILD_JAVAWS), true)
- SUBDIRS = $(JAVAWS_SUBDIR)
-+endif
- ifeq ($(BUILD_PLUGIN), true)
- SUBDIR += $(PLUGIN_SUBDIR)
- endif
-@@ -47,7 +59,9 @@
- done
-
- javaws-all: sanity-javaws
-+ ifeq ($(BUILD_JAVAWS), true)
- $(CD) $(BUILDDIR)/javaws ; $(MAKE) installer-int dev-all doc aubundle
-+ endif
-
- plugin-all: sanity-plugin
- ifeq ($(BUILD_PLUGIN), true)
diff --git a/java/jdk16/files/patch-font.properties.zh_TW.bsd b/java/jdk16/files/patch-font.properties.zh_TW.bsd
deleted file mode 100644
index a142781b2ee2..000000000000
--- a/java/jdk16/files/patch-font.properties.zh_TW.bsd
+++ /dev/null
@@ -1,302 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/solaris/classes/sun/awt/motif/font.properties.zh_TW.bsd.orig 16 Aug 2002 06:04:59 -0000 1.1
-+++ ../../j2se/src/solaris/classes/sun/awt/motif/font.properties.zh_TW.bsd 1 Mar 2004 21:40:08 -0000 1.2
-@@ -1,235 +1,178 @@
-+# %W% %E%
- #
--# @(#)font.properties.zh 1.0 00/06/20
--#
--# Copyright 2000 by Sun Microsystems, Inc.,
--# 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
--# All rights reserved.
--#
--# This software is the confidential and proprietary information
--# of Sun Microsystems, Inc. ("Confidential Information"). You
--# shall not disclose such Confidential Information and shall use
--# it only in accordance with the terms of the license agreement
--# you entered into with Sun.
--#
--
--#
--# AWT Font default Properties for Simplified Chinese TurboLinux 6.0 and higher
-+# Copyright 2002 Sun Microsystems, Inc. All rights reserved.
- #
-
--# Serif font definition
-+# Component Font Mappings For RedhatLinux 8.0/zh_TW
- #
- serif.0=-b&h-lucidabright-medium-r-normal--*-%d-*-*-p-*-iso8859-1
--serif.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.italic.0=-b&h-lucidabright-medium-i-normal--*-%d-*-*-p-*-iso8859-1
--serif.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.bold.0=-b&h-lucidabright-demibold-r-normal--*-%d-*-*-p-*-iso8859-1
--serif.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- serif.bolditalic.0=-b&h-lucidabright-demibold-i-normal--*-%d-*-*-p-*-iso8859-1
--serif.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+serif.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# SansSerif font definition
--#
- sansserif.0=-b&h-lucidasans-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.italic.0=-b&h-lucidasans-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.bold.0=-b&h-lucidasans-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- sansserif.bolditalic.0=-b&h-lucidasans-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--sansserif.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+sansserif.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Monospaced font definition
--#
- monospaced.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--monospaced.italic.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.italic.0=-b&h-lucidatypewriter-medium-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+monospaced.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- monospaced.bold.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--monospaced.bolditalic.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--monospaced.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+monospaced.bolditalic.0=-b&h-lucidatypewriter-bold-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+monospaced.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Dialog font definition
--#
- dialog.0=-b&h-lucidasans-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.italic.0=-b&h-lucidasans-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.bold.0=-b&h-lucidasans-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialog.bolditalic.0=-b&h-lucidasans-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1
--dialog.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialog.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# DialogInput font definition
--#
- dialoginput.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--dialoginput.italic.0=-b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.italic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.italic.0=-b&h-lucidatypewriter-medium-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+dialoginput.italic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
- dialoginput.bold.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.bold.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
--
--dialoginput.bolditalic.0=-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1
--dialoginput.bolditalic.1=-Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+dialoginput.bold.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
-+dialoginput.bolditalic.0=-b&h-lucidatypewriter-bold-i-normal-sans-*-%d-*-*-m-*-iso8859-1
-+dialoginput.bolditalic.1=-arphic technology co.-ar pl mingti2l big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1
-
--# Default font definition
-+# Missing Glyph Character
- #
- default.char=274f
-
--# name aliases
--#
--# alias.timesroman=serif
--# alias.helvetica=sansserif
--# alias.courier=monospaced
--
--# for backward compatibility
--#
--#zapfdingbats.0=-monotype-monotype sorts-regular-r---*-%d-*-*-p-*-adobe-dingbats
--
--# Static FontCharset info.
--#
--# This information is used by the font which is not indexed by Unicode.
--# Such fonts can use their own subclass of FontCharset.
--#
--# This information can be overriden by describing more specific style.
--# For example
--#
--# fontcharset.serif.plain.3=SpecialSymbols
--# means serif.plain.3 font's index can be retrieved with the convert() method
--# of instance of SpecialSymbols and what kind of characters serif.plain.3 font
--# has can be judged with the isCovered() method of instance of SpecialSymbols.
-+# Component Font Character Encodings
- #
- fontcharset.serif.0=sun.io.CharToByteISO8859_1
--fontcharset.serif.1=sun.io.CharToByteMS950
-+fontcharset.serif.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.sansserif.0=sun.io.CharToByteISO8859_1
--fontcharset.sansserif.1=sun.io.CharToByteMS950
-+fontcharset.sansserif.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.monospaced.0=sun.io.CharToByteISO8859_1
--fontcharset.monospaced.1=sun.io.CharToByteMS950
-+fontcharset.monospaced.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.dialog.0=sun.io.CharToByteISO8859_1
--fontcharset.dialog.1=sun.io.CharToByteMS950
-+fontcharset.dialog.1=sun.io.CharToByteUnicodeBigUnmarked
-
- fontcharset.dialoginput.0=sun.io.CharToByteISO8859_1
--fontcharset.dialoginput.1=sun.io.CharToByteMS950
-+fontcharset.dialoginput.1=sun.io.CharToByteUnicodeBigUnmarked
-
--# exclusion info.
--#
--# This information describe exclusion ranges for each fonts.
--#
--# 'exclusion.serif.plain.0' overrides 'exclusion.serif.0', and
--# 'exclusion.serif.0' overrides exclusion.0, and so on.
-+# Exclusion Ranges
- #
-
--# XFontSet string
--# X11 only properties
-+# XFontSet Information
- #
- fontset.serif.plain=\
- -b&h-lucidabright-medium-r-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.italic=\
- -b&h-lucidabright-medium-i-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.bold=\
- -b&h-lucidabright-demibold-r-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.serif.bolditalic=\
- -b&h-lucidabright-demibold-i-normal--*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
--
--# SansSerif font definition
--#
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.plain=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.italic=\
- -b&h-lucida-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.bold=\
---b&h-lucida-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.sansserif.bolditalic=\
---b&h-lucida-bold-i-normal-snas-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# Monospaced font definition
--#
- fontset.monospaced.plain=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.italic=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.bold=\
---b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-,1\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.monospaced.bolditalic=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# Dialog font definition
--#
- fontset.dialog.italic=\
- -b&h-lucida-medium-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.bold=\
- -b&h-lucida-bold-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.bolditalic=\
- -b&h-lucida-bold-i-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialog.plain=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--# DialogInput font definition
--#
- fontset.dialoginput.italic=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.bold=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.bolditalic=\
- -b&h-lucidatypewriter-bold-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
- fontset.dialoginput.plain=\
- -b&h-lucidatypewriter-medium-r-normal-sans-*-%d-*-*-m-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-
--#
- fontset.default=\
- -b&h-lucida-medium-r-normal-sans-*-%d-*-*-p-*-iso8859-1,\
---Arphic-AR PL Mingti2L Big5-medium-r-normal--*-%d-*-*-c-*-big5-0
-+-kc-fixed-medium-r-normal--*-%d-*-*-c-*-big5-0
-+
-+filename.-arphic_technology_co.-ar_pl_mingti2l_big5-medium-r-normal--*-%d-*-*-c-*-iso10646-1=/usr/local/share/fonts/TrueType/bsmi00lp.ttf
diff --git a/java/jdk16/files/patch-hpi_monitor_md.c b/java/jdk16/files/patch-hpi_monitor_md.c
deleted file mode 100644
index ca874dd9cd35..000000000000
--- a/java/jdk16/files/patch-hpi_monitor_md.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- ../../j2se/src/solaris/hpi/native_threads/src/monitor_md.c 22 Oct 2003 23:03:43 -0000 1.1.1.2
-+++ ../../j2se/src/solaris/hpi/native_threads/src/monitor_md.c 21 Oct 2004 05:42:52 -0000
-@@ -129,7 +129,7 @@
- mid->monitor_owner = self;
- mid->entry_count = 1;
- return SYS_OK;
-- } else if (err == EBUSY) { /* it's already locked */
-+ } else if (err == EBUSY || err == EDEADLK) { /* it's already locked */
- if (mid->monitor_owner == self) {
- mid->entry_count++;
- return SYS_OK;
diff --git a/java/jdk16/files/patch-interpreter_bytecodes.hpp b/java/jdk16/files/patch-interpreter_bytecodes.hpp
deleted file mode 100644
index 112722cac07e..000000000000
--- a/java/jdk16/files/patch-interpreter_bytecodes.hpp
+++ /dev/null
@@ -1,24 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/share/vm/interpreter/bytecodes.hpp 22 Oct 2003 23:05:03 -0000 1.1.1.3
-+++ ../../hotspot/src/share/vm/interpreter/bytecodes.hpp 12 Oct 2004 05:27:27 -0000
-@@ -6,6 +6,9 @@
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-+
-+#include <limits.h>
-+
- // Bytecodes specifies all bytecodes used in the VM and
- // provides utility functions to get bytecode attributes.
-
-@@ -236,7 +239,8 @@
- // Platform specific JVM bytecodes
- #include "incls/_bytecodes_pd.hpp.incl"
-
-- number_of_codes
-+ number_of_codes,
-+ WIDTH_HINT = INT_MAX
- };
-
- private:
diff --git a/java/jdk16/files/patch-interpreter_shared.hpp b/java/jdk16/files/patch-interpreter_shared.hpp
deleted file mode 100644
index 25feb1ff8da9..000000000000
--- a/java/jdk16/files/patch-interpreter_shared.hpp
+++ /dev/null
@@ -1,38 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/share/vm/interpreter/shared.hpp 22 Oct 2003 23:05:05 -0000 1.1.1.2
-+++ ../../hotspot/src/share/vm/interpreter/shared.hpp 10 Oct 2004 05:03:55 -0000
-@@ -41,19 +41,17 @@
- // to control the C++ namespace.
- class OptoReg VALUE_OBJ_CLASS_SPEC {
- public:
-- enum Name {
-- // Chunk 0
-+ typedef int Name;
- #ifdef COMPILER2
-- Physical = AdlcVMDeps::Physical, // Start of physical regs
-+ static const Name Physical = AdlcVMDeps::Physical; // Start of physical regs
- #endif
- // A few oddballs at the edge of the world
-- Special = -2, // All special (not allocated) values
-- Bad = -1 // Not a register
-- };
-+ static const Name Special = -2; // All special (not allocated) values
-+ static const Name Bad = -1; // Not a register
-
- // Increment a register number. As in:
- // "for ( OptoReg::Name i; i=Control; i = add(i,1) ) ..."
-- static Name add( Name x, int y ) { return Name(x+y); }
-+ static Name add( Name x, int y ) { return (x+y); }
-
- // (We would like to have an operator+ for RegName, but it is not
- // a class, so this would be illegal in C++.)
-@@ -70,7 +68,7 @@
- // when we do not yet know how big the frame will be.
- class VMReg VALUE_OBJ_CLASS_SPEC {
- public:
-- enum Name { };
-+ typedef int Name;
- };
-
-
diff --git a/java/jdk16/files/patch-io_io_util.h b/java/jdk16/files/patch-io_io_util.h
deleted file mode 100644
index 80f00417aa2b..000000000000
--- a/java/jdk16/files/patch-io_io_util.h
+++ /dev/null
@@ -1,21 +0,0 @@
-$FreeBSD$
-
---- ../../j2se/src/share/native/java/io/io_util.h.orig Wed Jul 21 08:32:49 2004
-+++ ../../j2se/src/share/native/java/io/io_util.h Wed Jul 21 08:37:54 2004
-@@ -10,7 +10,15 @@
-
- extern jfieldID IO_fd_fdID;
-
--#if !defined(O_DSYNC) || !defined(O_SYNC)
-+#ifdef _BSD_SOURCE
-+#include <fcntl.h>
-+#ifndef O_SYNC
-+#define O_SYNC O_FSYNC
-+#endif
-+#ifndef O_DSYNC
-+#define O_DSYNC O_FSYNC
-+#endif
-+#elif !defined(O_DSYNC) || !defined(O_SYNC)
- #define O_SYNC (0x0800)
- #define O_DSYNC (0x2000)
- #endif
diff --git a/java/jdk16/files/patch-javascript_JSClassLoader.java b/java/jdk16/files/patch-javascript_JSClassLoader.java
deleted file mode 100644
index 1e3a9ad3080b..000000000000
--- a/java/jdk16/files/patch-javascript_JSClassLoader.java
+++ /dev/null
@@ -1,243 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSClassLoader.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSClassLoader.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,238 @@
-+/*
-+ * @(#)JSClassLoader.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+
-+package sun.plugin.javascript;
-+
-+import java.security.AllPermission;
-+import java.security.AccessController;
-+import java.security.PermissionCollection;
-+import java.security.SecureClassLoader;
-+import java.security.PrivilegedExceptionAction;
-+import java.security.CodeSource;
-+import java.io.InputStream;
-+import java.io.BufferedInputStream;
-+import java.io.IOException;
-+import java.net.URL;
-+import java.net.URLConnection;
-+import java.net.HttpURLConnection;
-+import java.lang.reflect.Method;
-+import java.lang.reflect.InvocationTargetException;
-+import java.lang.reflect.AccessibleObject;
-+import sun.net.www.ParseUtil;
-+import sun.security.util.SecurityConstants;
-+
-+/*
-+ * Create a trampoline class for JavaScript to Java
-+ * method invocations.
-+ *
-+ */
-+public final class JSClassLoader extends SecureClassLoader {
-+ private static String JS_PROXY_PKG = "sun.plugin.javascript.invoke.";
-+ private static String TRAMPOLINE = JS_PROXY_PKG + "JSInvoke";
-+ private static Method bounce;
-+
-+ /*
-+ * Bounce through the trampoline.
-+ */
-+ public static Object invoke(Method m, Object obj, Object[] params)
-+ throws Exception {
-+ try {
-+ return bounce().invoke(null, new Object[] {m, obj, params});
-+ } catch (InvocationTargetException ie) {
-+ Throwable t = ie.getCause();
-+
-+ if (t instanceof InvocationTargetException) {
-+ throw (InvocationTargetException)t;
-+ } else {
-+ throw ie;
-+ }
-+ }
-+ }
-+
-+ /**
-+ * Check the package access permission by giving a class
-+ *
-+ * @param clazz: The Class object trying to get access to
-+ *
-+ */
-+ public static void checkPackageAccess(Class clazz) {
-+ String clsname = clazz.getName();
-+ int index = clsname.lastIndexOf(".");
-+ if (index != -1) {
-+ String pkgname = clsname.substring(0, index);
-+ SecurityManager s = System.getSecurityManager();
-+ if (s != null) {
-+ s.checkPackageAccess(pkgname);
-+ }
-+ }
-+ }
-+
-+ public static boolean isPackageAccessible(Class clazz) {
-+ try {
-+ checkPackageAccess(clazz);
-+ } catch (SecurityException e) {
-+ return false;
-+ }
-+ return true;
-+ }
-+
-+
-+ private synchronized static Method bounce() throws Exception {
-+ if (bounce == null) {
-+ bounce = (Method) AccessController.doPrivileged(new PrivilegedExceptionAction() {
-+ public Object run() throws Exception {
-+ Class[] types;
-+ Class t = getTrampoline();
-+ Method b;
-+
-+ types = new Class[] {Method.class, Object.class, Object[].class};
-+ b = t.getDeclaredMethod("invoke", types);
-+ ((AccessibleObject)b).setAccessible(true);
-+ return b;
-+ }
-+ });
-+ }
-+ return bounce;
-+ }
-+
-+ private static Class getTrampoline() {
-+ try {
-+ return Class.forName(TRAMPOLINE, true, new JSClassLoader());
-+ } catch (ClassNotFoundException e) {
-+ }
-+ return null;
-+ }
-+
-+
-+ protected synchronized Class loadClass(String name, boolean resolve)
-+ throws ClassNotFoundException
-+ {
-+ SecurityManager s = System.getSecurityManager();
-+ if (s != null) {
-+ String cname = name.replace('/', '.');
-+ if (cname.startsWith("[")) {
-+ int b = cname.lastIndexOf('[') + 2;
-+ if (b > 1 && b < cname.length()) {
-+ cname = cname.substring(b);
-+ }
-+ }
-+ int i = cname.lastIndexOf('.');
-+ if (i != -1) {
-+ s.checkPackageAccess(cname.substring(0, i));
-+ }
-+ }
-+ // First, check if the class has already been loaded
-+ Class c = findLoadedClass(name);
-+ if (c == null) {
-+ try {
-+ c = findClass(name);
-+ } catch (ClassNotFoundException e) {
-+ // Fall through ...
-+ }
-+ if (c == null) {
-+ c = getParent().loadClass(name);
-+ }
-+ }
-+ if (resolve) {
-+ resolveClass(c);
-+ }
-+ return c;
-+ }
-+
-+
-+ protected Class findClass(final String name)
-+ throws ClassNotFoundException
-+ {
-+ if (!name.startsWith(JS_PROXY_PKG)) {
-+ throw new ClassNotFoundException(name);
-+ }
-+ String path = name.replace('.', '/').concat(".class");
-+ URL res = getResource(path);
-+ if (res != null) {
-+ try {
-+ return defineClass(name, res);
-+ } catch (IOException e) {
-+ throw new ClassNotFoundException(name, e);
-+ }
-+ } else {
-+ throw new ClassNotFoundException(name);
-+ }
-+ }
-+
-+
-+ /*
-+ * Define the JavaScript proxy classes
-+ */
-+ private Class defineClass(String name, URL url) throws IOException {
-+ byte[] b = getBytes(url);
-+ CodeSource cs = new CodeSource(null, (java.security.cert.Certificate[])null);
-+ if (!name.equals(TRAMPOLINE)) {
-+ throw new IOException("JSClassLoader: bad name " + name);
-+ }
-+ return defineClass(name, b, 0, b.length, cs);
-+ }
-+
-+
-+ /*
-+ * Returns the contents of the specified URL as an array of bytes.
-+ */
-+ private static byte[] getBytes(URL url) throws IOException {
-+ URLConnection uc = url.openConnection();
-+ if (uc instanceof java.net.HttpURLConnection) {
-+ java.net.HttpURLConnection huc = (java.net.HttpURLConnection) uc;
-+ int code = huc.getResponseCode();
-+ if (code >= java.net.HttpURLConnection.HTTP_BAD_REQUEST) {
-+ throw new IOException("open HTTP connection failed.");
-+ }
-+ }
-+ int len = uc.getContentLength();
-+ InputStream in = new BufferedInputStream(uc.getInputStream());
-+
-+ byte[] b;
-+ try {
-+ if (len != -1) {
-+ // Read exactly len bytes from the input stream
-+ b = new byte[len];
-+ while (len > 0) {
-+ int n = in.read(b, b.length - len, len);
-+ if (n == -1) {
-+ throw new IOException("unexpected EOF");
-+ }
-+ len -= n;
-+ }
-+ } else {
-+ b = new byte[8192];
-+ int total = 0;
-+ while ((len = in.read(b, total, b.length - total)) != -1) {
-+ total += len;
-+ if (total >= b.length) {
-+ byte[] tmp = new byte[total * 2];
-+ System.arraycopy(b, 0, tmp, 0, total);
-+ b = tmp;
-+ }
-+ }
-+ // Trim array to correct size, if necessary
-+ if (total != b.length) {
-+ byte[] tmp = new byte[total];
-+ System.arraycopy(b, 0, tmp, 0, total);
-+ b = tmp;
-+ }
-+ }
-+ } finally {
-+ in.close();
-+ }
-+ return b;
-+ }
-+
-+
-+ protected PermissionCollection getPermissions(CodeSource codesource)
-+ {
-+ PermissionCollection perms = super.getPermissions(codesource);
-+ perms.add(new AllPermission());
-+ return perms;
-+ }
-+}
diff --git a/java/jdk16/files/patch-javascript_JSInvoke.java b/java/jdk16/files/patch-javascript_JSInvoke.java
deleted file mode 100644
index fc692b9cb9c1..000000000000
--- a/java/jdk16/files/patch-javascript_JSInvoke.java
+++ /dev/null
@@ -1,26 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSInvoke.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/JSInvoke.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,21 @@
-+/*
-+ * @(#)JSInvoke.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+
-+package sun.plugin.javascript.invoke;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.InvocationTargetException;
-+
-+/*
-+ * JavaScript to Java invocation trampoline class.
-+ */
-+class JSInvoke {
-+ private static Object invoke(Method m, Object obj, Object[] params)
-+ throws InvocationTargetException, IllegalAccessException {
-+ return m.invoke(obj, params);
-+ }
-+}
diff --git a/java/jdk16/files/patch-javascript_ReflectUtil.java b/java/jdk16/files/patch-javascript_ReflectUtil.java
deleted file mode 100644
index 827bd0c666ce..000000000000
--- a/java/jdk16/files/patch-javascript_ReflectUtil.java
+++ /dev/null
@@ -1,312 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/ReflectUtil.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/javascript/ReflectUtil.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,307 @@
-+/*
-+ * @(#)ReflectUtil.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+package sun.plugin.javascript;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Field;
-+import java.lang.reflect.Modifier;
-+import java.lang.reflect.InvocationTargetException;
-+import java.util.HashMap;
-+import java.util.ArrayList;
-+import java.util.List;
-+import java.util.Map;
-+import java.util.Iterator;
-+import sun.plugin.javascript.JSClassLoader;
-+
-+public class ReflectUtil {
-+ /*
-+ * Discover the public methods on public classes
-+ * and interfaces accessible to the calling
-+ * JavaScript code.
-+ */
-+ public static Method[] getJScriptMethods(Class cls) {
-+ List m = new ArrayList(); /* the valid methods we find */
-+
-+ /*
-+ * Temporary map of method signatures when we decide
-+ * that a simple call to target.getMethods() returns
-+ * inaccessible methods and we must search for alternative
-+ * supermethods that might be accessible. We can toss
-+ * this when we're done searching.
-+ */
-+ Map sigs = new HashMap();
-+
-+ while (cls != null) {
-+ boolean done = getPublicMethods(cls, m, sigs);
-+ if (done) {
-+ break;
-+ }
-+ getJScriptInterfaceMethods(cls, m, sigs);
-+ cls = cls.getSuperclass();
-+ }
-+ return (Method[]) m.toArray(new Method[m.size()]);
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ private static void getJScriptInterfaceMethods(Class cls, List m, Map sigs) {
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length; i++) {
-+ Class intf = intfs[i];
-+ boolean done = getPublicMethods(intf, m, sigs);
-+ if (!done) {
-+ getJScriptInterfaceMethods(intf, m, sigs);
-+ }
-+ }
-+ }
-+
-+ /*
-+ *
-+ * Process the methods in this class or interface
-+ */
-+ private static boolean getPublicMethods(Class cls, List m, Map sigs) {
-+ Method[] methods = null;
-+ try {
-+
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's methods. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return false;
-+ }
-+
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return false;
-+ }
-+
-+ methods = cls.getMethods();
-+ } catch (SecurityException se) {
-+ return false;
-+ }
-+
-+ /*
-+ * Check for inherited methods with non-public
-+ * declaring classes. They might override and hide
-+ * methods from their superclasses or
-+ * superinterfaces.
-+ */
-+ boolean done = true;
-+ for (int i=0; i < methods.length; i++) {
-+ Class dc = methods[i].getDeclaringClass();
-+ if (!Modifier.isPublic(dc.getModifiers())) {
-+ done = false;
-+ break;
-+ }
-+ }
-+
-+ /*
-+ * Belatedly initialize the signature map if
-+ * this is not the first time here.
-+ */
-+ if (sigs.isEmpty() && !m.isEmpty()) {
-+ initSignatureMap(m, sigs);
-+ }
-+
-+ if (done) {
-+ /*
-+ * We're done. Spray all the methods into
-+ * the list and then we're out of here.
-+ */
-+ for (int i=0; i < methods.length; i++) {
-+ addMethod(m, sigs, methods[i]);
-+ }
-+ } else {
-+ /*
-+ * Simulate cls.getDeclaredMethods() by
-+ * stripping away inherited methods.
-+ */
-+ for (int i=0; i < methods.length; i++) {
-+ Class dc = methods[i].getDeclaringClass();
-+ if (cls.equals(dc)) {
-+ addMethod(m, sigs, methods[i]);
-+ }
-+ }
-+ }
-+ return done;
-+ }
-+
-+ private static void initSignatureMap(List m, Map sigs) {
-+ Iterator i = m.iterator();
-+ while (i.hasNext()) {
-+ Method entry = (Method) i.next();
-+ sigs.put(getSignature(entry), entry);
-+ }
-+ }
-+
-+ private static void addMethod(List m, Map sigs, Method method) {
-+ /*
-+ * Avoid work. We ignore the signature matching
-+ * until the map is initialized in initSignatureMap.
-+ * This has the effect of avoiding the signature
-+ * work for the first call of getPublicMethods().
-+ */
-+ if (sigs.isEmpty()) {
-+ m.add(method);
-+ return;
-+ }
-+
-+ /*
-+ * Avoid adding duplicate accessible methods on
-+ * the list.
-+ */
-+ String signature = getSignature(method);
-+ if (!sigs.containsKey(signature)) {
-+ m.add(method);
-+ sigs.put(signature, method);
-+ }
-+ }
-+
-+ /*
-+ * Return a canonical method signature for the method.
-+ * We care only about the simple method name and the
-+ * the number, type and order of the parameters.
-+ * Exception declarations are not part of a method
-+ * signature nor is the return type.
-+ */
-+ private static String getSignature(Method method) {
-+ StringBuffer sb = new StringBuffer();
-+
-+ sb.append(method.getName());
-+ Class[] params = method.getParameterTypes();
-+ sb.append('(');
-+ if (params.length > 0) {
-+ sb.append(params[0].getName());
-+ }
-+ for (int i=1; i < params.length; i++) {
-+ sb.append(',');
-+ sb.append(params[i].getName());
-+ }
-+ sb.append(')');
-+
-+ return sb.toString();
-+ }
-+
-+ /*
-+ * Discover the public fields on public classes
-+ * and interfaces accessible to the calling
-+ * JavaScript code.
-+ */
-+ public static Field[] getJScriptFields(Class cls) {
-+ List m = new ArrayList(); /* the valid fields we find */
-+
-+ /*
-+ * Temporary map of field name when we decide
-+ * that a simple call to target.getFields() returns
-+ * inaccessible fields and we must search for alternative
-+ * supermethods that might be accessible. We can toss
-+ * this when we're done searching.
-+ */
-+ Map names = new HashMap();
-+
-+ while (cls != null) {
-+ boolean done = getPublicFields(cls, m, names);
-+ if (done) {
-+ break;
-+ }
-+ getJScriptInterfaceFields(cls, m, names);
-+ cls = cls.getSuperclass();
-+ }
-+ return (Field[]) m.toArray(new Field[m.size()]);
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ private static void getJScriptInterfaceFields(Class cls, List m, Map names) {
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length; i++) {
-+ Class intf = intfs[i];
-+ boolean done = getPublicFields(intf, m, names);
-+ if (!done) {
-+ getJScriptInterfaceFields(intf, m, names);
-+ }
-+ }
-+ }
-+
-+ /*
-+ *
-+ * Process the fields in this class or interface
-+ */
-+ private static boolean getPublicFields(Class cls, List m, Map names) {
-+ Field[] fields = null;
-+ try {
-+
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's fields. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return false;
-+ }
-+
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return false;
-+ }
-+ fields = cls.getFields();
-+ } catch (SecurityException se) {
-+ return false;
-+ }
-+
-+ /*
-+ * Check for inherited fields with non-public
-+ * declaring classes. They might hide
-+ * fields from public classes or interfaces.
-+ */
-+ boolean done = true;
-+ for (int i=0; i < fields.length; i++) {
-+ Class dc = fields[i].getDeclaringClass();
-+ if (!Modifier.isPublic(dc.getModifiers())) {
-+ done = false;
-+ break;
-+ }
-+ }
-+ if (done) {
-+ /*
-+ * We're done. Spray all the fields into
-+ * the list and then we're out of here.
-+ */
-+ for (int i=0; i < fields.length; i++) {
-+ addField(m, names, fields[i]);
-+ }
-+ } else {
-+ /*
-+ * Simulate cls.getDeclaredFields() by
-+ * stripping away inherited fields.
-+ */
-+ for (int i=0; i < fields.length; i++) {
-+ Class dc = fields[i].getDeclaringClass();
-+ if (cls.equals(dc)) {
-+ addField(m, names, fields[i]);
-+ }
-+ }
-+ }
-+ return done;
-+ }
-+
-+ private static void addField(List m, Map names, Field field) {
-+ /*
-+ * Avoid adding duplicate accessible fields on
-+ * the list.
-+ */
-+ String name = field.getName();
-+ if (!names.containsKey(name)) {
-+ m.add(field);
-+ names.put(name, field);
-+ }
-+ }
-+}
-+
-+
diff --git a/java/jdk16/files/patch-liveconnect_ReplaceMethod.java b/java/jdk16/files/patch-liveconnect_ReplaceMethod.java
deleted file mode 100644
index 829e43452e6c..000000000000
--- a/java/jdk16/files/patch-liveconnect_ReplaceMethod.java
+++ /dev/null
@@ -1,93 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/ReplaceMethod.java 1 Jan 1970 00:00:00 -0000
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/ReplaceMethod.java 3 Dec 2004 03:56:58 -0000 1.1
-@@ -0,0 +1,88 @@
-+/*
-+ * @(#)ReplaceMethod.java 1.1 04/06/20
-+ *
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
-+ * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-+ */
-+package sun.plugin.liveconnect;
-+
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Modifier;
-+import sun.plugin.javascript.JSClassLoader;
-+
-+public class ReplaceMethod {
-+ /*
-+ * Replace the inaccessible method by a suitable method on public
-+ * class/interface accessible to the calling JavaScript code.
-+ * Returns null if accessible method is not found.
-+ */
-+ static Method getJScriptMethod(Method start) {
-+ Class cls = start.getDeclaringClass();
-+
-+ if (Modifier.isPublic(cls.getModifiers())) {
-+ return start;
-+ }
-+
-+ String name = start.getName();
-+ Class[] params = start.getParameterTypes();
-+
-+ Method result = null;
-+ while (cls != null && result == null) {
-+ result = getPublicMethod(cls, name, params);
-+ if (result == null) {
-+ result = getJScriptInterfaceMethod(cls, name, params);
-+ }
-+ cls = cls.getSuperclass();
-+ }
-+ return result;
-+ }
-+
-+ /*
-+ * Process the immediate interfaces of this class or interface.
-+ */
-+ static Method getJScriptInterfaceMethod(Class cls, String name, Class[] params) {
-+ Method result = null;
-+ Class[] intfs = cls.getInterfaces();
-+ for (int i=0; i < intfs.length && result == null; i++) {
-+ Class intf = intfs[i];
-+ result = getPublicMethod(intf, name, params);
-+ if (result == null) {
-+ result = getJScriptInterfaceMethod(intf, name, params);
-+ }
-+ }
-+ return result;
-+ }
-+
-+ /*
-+ *
-+ * Process the methods in this class or interface
-+ */
-+ static private Method getPublicMethod(Class cls, String name, Class[] params) {
-+ try {
-+ /*
-+ * This class or interface is non-public so we
-+ * can't use any of it's methods. Go back and
-+ * try again with a superclass or superinterface.
-+ */
-+ if (!Modifier.isPublic(cls.getModifiers())) {
-+ return null;
-+ }
-+
-+ /*
-+ * This call will fail if 'cls' is in a restricted
-+ * package and we don't have permission to access
-+ * it.
-+ */
-+ if (!JSClassLoader.isPackageAccessible(cls)) {
-+ return null;
-+ }
-+ return cls.getMethod(name, params);
-+ } catch (NoSuchMethodException nsme) {
-+ return null;
-+ } catch (SecurityException se) {
-+ return null;
-+ }
-+ }
-+}
-+
-+
diff --git a/java/jdk16/files/patch-liveconnect_SecureInvocation.java b/java/jdk16/files/patch-liveconnect_SecureInvocation.java
deleted file mode 100644
index 961414277909..000000000000
--- a/java/jdk16/files/patch-liveconnect_SecureInvocation.java
+++ /dev/null
@@ -1,351 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/SecureInvocation.java 22 Oct 2003 23:04:21 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/liveconnect/SecureInvocation.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
- * @(#)SecureInvocation.java 1.21 02/08/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,7 +9,8 @@
-
- import java.lang.reflect.Constructor;
- import java.lang.reflect.Field;
--import java.lang.reflect.Method;
-+import java.lang.reflect.Method;
-+import java.lang.reflect.Modifier;
- import java.lang.Thread;
- import java.io.FilePermission;
- import java.security.AccessControlContext;
-@@ -29,7 +30,10 @@
- import java.net.URL;
- import java.net.MalformedURLException;
- import sun.plugin.util.Trace;
--import sun.plugin.services.PlatformService;
-+import sun.plugin.services.PlatformService;
-+import sun.plugin.javascript.JSClassLoader;
-+import sun.plugin.javascript.ReflectUtil;
-+
-
- /**
- * <P> SecureInvocation is for implementating nsISecureJNI which allows
-@@ -98,64 +102,64 @@
- throw e;
- }
- }
--
-- static class CallMethodThread extends Thread {
-- public CallMethodThread(int handle, Class clazz, Object obj, Method method, Object[] args,
-- String origin, boolean isUniversalBrowserRead,
-- boolean isUniversalJavaPermission) {
-- this.handle = handle;
-- this.clazz = clazz;
-- this.obj = obj;
-- this.method = method;
-- this.args = args;
-- this.origin = origin;
-- this.isUniversalBrowserRead = isUniversalBrowserRead;
-- this.isUniversalJavaPermission = isUniversalJavaPermission;
-- }
--
-- public void run() {
-- try {
-- result = CallMethod(clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-- }
-- catch(Exception e) {
-- exception = e;
-- }
-- finally {
-- PlatformService.getService().signalEvent(handle);
-- }
-- }
--
--
-- public Object getResult() throws Exception {
-- if(exception != null)
-- throw exception;
-- return result;
-- }
--
-- private Exception exception = null;
-- private Object result = null;
--
-- private int handle;
-- private Class clazz;
-- private Object obj;
-- private Method method;
-- private Object[] args;
-- private String origin;
-- private boolean isUniversalBrowserRead;
-- private boolean isUniversalJavaPermission;
--
-- }
--
-- public static Object CallMethod(final int handle, final Class clazz, final Object obj, final Method method, final Object[] args,
-- final String origin, final boolean isUniversalBrowserRead,
-- final boolean isUniversalJavaPermission)
-- throws Exception {
-- CallMethodThread callThread = new CallMethodThread(handle, clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-- callThread.start();
-- PlatformService.getService().waitEvent(handle);
-- return callThread.getResult();
-- }
--
-+
-+ static class CallMethodThread extends Thread {
-+ public CallMethodThread(int handle, Class clazz, Object obj, Method method, Object[] args,
-+ String origin, boolean isUniversalBrowserRead,
-+ boolean isUniversalJavaPermission) {
-+ this.handle = handle;
-+ this.clazz = clazz;
-+ this.obj = obj;
-+ this.method = method;
-+ this.args = args;
-+ this.origin = origin;
-+ this.isUniversalBrowserRead = isUniversalBrowserRead;
-+ this.isUniversalJavaPermission = isUniversalJavaPermission;
-+ }
-+
-+ public void run() {
-+ try {
-+ result = CallMethod(clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-+ }
-+ catch(Exception e) {
-+ exception = e;
-+ }
-+ finally {
-+ PlatformService.getService().signalEvent(handle);
-+ }
-+ }
-+
-+
-+ public Object getResult() throws Exception {
-+ if(exception != null)
-+ throw exception;
-+ return result;
-+ }
-+
-+ private Exception exception = null;
-+ private Object result = null;
-+
-+ private int handle;
-+ private Class clazz;
-+ private Object obj;
-+ private Method method;
-+ private Object[] args;
-+ private String origin;
-+ private boolean isUniversalBrowserRead;
-+ private boolean isUniversalJavaPermission;
-+
-+ }
-+
-+ public static Object CallMethod(final int handle, final Class clazz, final Object obj, final Method method, final Object[] args,
-+ final String origin, final boolean isUniversalBrowserRead,
-+ final boolean isUniversalJavaPermission)
-+ throws Exception {
-+ CallMethodThread callThread = new CallMethodThread(handle, clazz, obj, method, args, origin, isUniversalBrowserRead, isUniversalJavaPermission);
-+ callThread.start();
-+ PlatformService.getService().waitEvent(handle);
-+ return callThread.getResult();
-+ }
-+
-
- /**
- * <P> Call a method on Java object with security context.
-@@ -197,8 +201,8 @@
- AccessControlContext context = new AccessControlContext(domains);
-
- // Perform the method invocation.
-- return AccessController.doPrivileged(new PrivilegedCallMethodAction(method, obj, args),
-- context);
-+ return AccessController.doPrivileged(new PrivilegedCallMethodAction(method,
-+ obj, args), context);
- } catch (Exception e) {
- Trace.liveConnectPrintException(e);
- throw e;
-@@ -323,32 +327,6 @@
- }
- }
-
--
-- /**
-- * <P> Set up a protection domain according to the origin and
-- * the other security related information.
-- */
-- private static ProtectionDomain getProtectionDomain(Class clazz,
-- String origin,
-- boolean byPassOrigin,
-- boolean allPermission)
-- throws OriginNotAllowedException, MalformedURLException
-- {
-- boolean trust = false;
--
-- // First, check if the call is allowed
-- checkLiveConnectCaller(clazz, origin, byPassOrigin);
--
-- if (allPermission)
-- {
-- return getTrustedProtectionDomain();
-- }
-- else
-- {
-- return getDefaultProtectionDomain(origin);
-- }
-- }
--
- /**
- * <P> Check if LiveConnect call is allowed at all.
- * </P>
-@@ -447,7 +425,7 @@
-
- // Obtain Java policy
- Policy policy = Policy.getPolicy();
-- CodeSource cs = new CodeSource(url, null);
-+ CodeSource cs = new CodeSource(url, (java.security.cert.Certificate[])null);
- final PermissionCollection pc = policy.getPermissions(cs);
-
- if (url == null || url.getProtocol().equals("file")) {
-@@ -516,16 +494,19 @@
-
- PrivilegedConstructObjectAction(Constructor constructor, Object[] args)
- {
-- this.constructor = constructor;
-- this.args = args;
-+ this.constructor = constructor;
-+ this.args = args;
-
-- // Ensure the argument is not null
-- if (this.args == null)
-- this.args = new Object[0];
-+ // Ensure the argument is not null
-+ if (this.args == null)
-+ this.args = new Object[0];
- }
-
- public Object run() throws Exception {
-- return constructor.newInstance(args);
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(constructor.getDeclaringClass());
-+
-+ return constructor.newInstance(args);
- }
- }
-
-@@ -543,17 +524,54 @@
-
- PrivilegedCallMethodAction(Method method, Object obj, Object[] args)
- {
-- this.method = method;
-- this.obj = obj;
-- this.args = args;
--
-- // Ensure the argument is not null
-- if (this.args == null)
-- this.args = new Object[0];
-+ this.method = method;
-+
-+ this.obj = obj;
-+ this.args = args;
-+
-+ // Ensure the argument is not null
-+ if (this.args == null)
-+ this.args = new Object[0];
- }
-
- public Object run() throws Exception {
-- return method.invoke(obj, args);
-+ /*
-+ * Browser uses reflection to collect methods/fields/constructors
-+ * through this method call. Therefore JSClassLoader is not used
-+ * in such cases. However it requires filtering to avoid exposing
-+ * inaccessible methods/fields/constructors.
-+ *
-+ * Also, Mozilla ignores abstract methods, therefore those are
-+ * replaced by the concrete class methods
-+ */
-+ if(obj instanceof Class) {
-+ String name = method.getName();
-+ Class cls = (Class)obj;
-+ if(name.equals("getMethods")) {
-+ Method[] methods = ReflectUtil.getJScriptMethods(cls);
-+ for (int i=0; i < methods.length; i++) {
-+ Method m = methods[i];
-+ if (Modifier.isAbstract(m.getModifiers())) {
-+ Class[] params = m.getParameterTypes();
-+ methods[i] = cls.getMethod(m.getName(), params);
-+ }
-+ }
-+ return methods;
-+ }else if (name.equals("getFields")) {
-+ return ReflectUtil.getJScriptFields(cls);
-+ }else if (name.equals("getConstructors")) {
-+ if (!Modifier.isPublic(cls.getModifiers()) ||
-+ !JSClassLoader.isPackageAccessible(cls)) {
-+ return new Constructor[0];
-+ }
-+ }
-+ }
-+
-+ Method actualMethod = ReplaceMethod.getJScriptMethod(method);
-+ if(actualMethod != null)
-+ return JSClassLoader.invoke(actualMethod, obj, args);
-+ else
-+ throw new NoSuchMethodException(method.getName());
- }
- }
-
-@@ -564,18 +582,20 @@
- * </P>
- */
- class PrivilegedGetFieldAction implements PrivilegedExceptionAction {
--
- Field field;
- Object obj;
-
- PrivilegedGetFieldAction(Field field, Object obj)
- {
-- this.field = field;
-- this.obj = obj;
-+ this.field = field;
-+ this.obj = obj;
- }
-
-- public Object run() throws Exception {
-- return field.get(obj);
-+ public Object run() throws Exception {
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(field.getDeclaringClass());
-+
-+ return field.get(obj);
- }
- }
-
-@@ -593,15 +613,18 @@
-
- PrivilegedSetFieldAction(Field field, Object obj, Object val)
- {
-- this.field = field;
-- this.obj = obj;
-- this.val = val;
-+ this.field = field;
-+ this.obj = obj;
-+ this.val = val;
- }
-
- public Object run() throws Exception {
-- field.set(obj, val);
-+ /* Check whether the caller has package access permission */
-+ JSClassLoader.checkPackageAccess(field.getDeclaringClass());
-+
-+ field.set(obj, val);
- return null;
- }
- }
--
--
-+
-+
diff --git a/java/jdk16/files/patch-native::util.c b/java/jdk16/files/patch-native::util.c
deleted file mode 100644
index 719d1ae0e989..000000000000
--- a/java/jdk16/files/patch-native::util.c
+++ /dev/null
@@ -1,16 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/javaws/src/share/native/util.c 22 Oct 2003 23:04:17 -0000 1.1.1.1
-+++ ../../deploy/src/javaws/src/share/native/util.c 16 Jan 2004 23:50:11 -0000
-@@ -27,7 +27,10 @@
-
- /* Find size of file */
- struct stat statBuf;
-- stat(filename, &statBuf);
-+ if (stat(filename, &statBuf) == -1) {
-+ *buffer = NULL;
-+ return 0;
-+ }
- size = statBuf.st_size;
-
- /* Allocate memory for contents */
diff --git a/java/jdk16/files/patch-nspr_pth.h b/java/jdk16/files/patch-nspr_pth.h
deleted file mode 100644
index c2a1cb5d5ed1..000000000000
--- a/java/jdk16/files/patch-nspr_pth.h
+++ /dev/null
@@ -1,11 +0,0 @@
---- ../../deploy/src/plugin/oji-plugin/include/solaris/navig4/nspr/md/_pth.h 22 Oct 2003 23:04:19 -0000 1.1.1.1
-+++ ../../deploy/src/plugin/oji-plugin/include/solaris/navig4/nspr/md/_pth.h 21 Oct 2004 05:47:13 -0000
-@@ -52,7 +52,7 @@
- #define PTHREAD_MUTEXATTR_INIT pthread_mutexattr_init
- #define PTHREAD_MUTEXATTR_DESTROY pthread_mutexattr_destroy
- #define PTHREAD_MUTEX_INIT(m, a) pthread_mutex_init(&(m), &(a))
--#define PTHREAD_MUTEX_IS_LOCKED(m) (EBUSY == pthread_mutex_trylock(&(m)))
-+#define PTHREAD_MUTEX_IS_LOCKED(m) (0 != pthread_mutex_trylock(&(m)))
- #define PTHREAD_CONDATTR_INIT pthread_condattr_init
- #define PTHREAD_CONDATTR_DESTROY pthread_condattr_destroy
- #define PTHREAD_COND_INIT(m, a) pthread_cond_init(&(m), &(a))
diff --git a/java/jdk16/files/patch-plugin_DispatchImpl.java b/java/jdk16/files/patch-plugin_DispatchImpl.java
deleted file mode 100644
index abb65a60953e..000000000000
--- a/java/jdk16/files/patch-plugin_DispatchImpl.java
+++ /dev/null
@@ -1,331 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/com/DispatchImpl.java 22 Oct 2003 23:04:20 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/com/DispatchImpl.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
-- * @(#)DispatchImpl.java 1.6 03/01/23
-+ * @(#)DispatchImpl.java 1.16 04/06/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,8 +9,32 @@
-
- import sun.plugin.util.Trace;
- import sun.plugin.javascript.ocx.JSObject;
--import java.applet.Applet;
-+import sun.plugin.liveconnect.JavaScriptProtectionDomain;
- import sun.plugin.viewer.context.IExplorerAppletContext;
-+import sun.plugin.security.PluginClassLoader;
-+import java.applet.Applet;
-+import java.net.URL;
-+import java.net.MalformedURLException;
-+import java.net.InetAddress;
-+import java.net.UnknownHostException;
-+import java.net.SocketPermission;
-+import java.io.FilePermission;
-+import java.io.File;
-+import java.security.AccessControlContext;
-+import java.security.AccessController;
-+import java.security.CodeSource;
-+import java.security.Policy;
-+import java.security.ProtectionDomain;
-+import java.security.AllPermission;
-+import java.security.Permissions;
-+import java.security.Permission;
-+import java.security.PermissionCollection;
-+import java.security.PrivilegedAction;
-+import java.security.PrivilegedExceptionAction;
-+import java.security.AccessControlException;
-+import java.security.PrivilegedActionException;
-+import sun.net.www.ParseUtil;
-+import sun.security.util.SecurityConstants;
-
- /**
- * DispatchImpl encapsulates a Java Object and provides Dispatch interface
-@@ -22,14 +46,19 @@
- {
- JavaClass targetClass = null;
- Object targetObj = null;
-+ int handle = 0;
-+ int wndHandle = 0;
-+ AccessControlContext context = null;
-+ boolean isBridge = false;
-
- /*
- * Constructor
- * @param obj the object to be wrapped
- */
-- public DispatchImpl(Object obj)
-+ public DispatchImpl(Object obj, int id)
- {
- targetObj = obj;
-+ handle = id;
- }
-
- /**
-@@ -40,19 +69,87 @@
- * @param params Arguments.
- * @return Java object.
- */
-- public Object invoke(int flag, int index, Object []params)
-+ public Object invoke(final int flag, final int index, final Object []params)
-+ throws Exception
-+ {
-+ try {
-+ //No security constraints in case of ActiveX bridge application
-+ if(isBridge)
-+ return invokeImpl(flag, index, params);
-+
-+ if(context == null) {
-+ context = createContext();
-+ }
-+
-+ // Invoke the method within the applet sand box security restricitions
-+ return AccessController.doPrivileged(
-+ new PrivilegedExceptionAction() {
-+ public Object run() throws Exception{
-+ return invokeImpl(flag, index, params);
-+ }
-+ }, context
-+ );
-+ }catch(Exception exc) {
-+ Throwable cause = exc.getCause();
-+ if(cause == null) {
-+ cause = exc;
-+ }
-+
-+ Trace.liveConnectPrintException(cause);
-+ throw new Exception(cause.toString());
-+ }
-+ }
-+
-+ public AccessControlContext createContext() {
-+ try {
-+ ProtectionDomain[] domains = new ProtectionDomain[1];
-+ //Obtain the java code origin
-+ ProtectionDomain pd = (ProtectionDomain)AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ return targetObj.getClass().getProtectionDomain();
-+ }
-+ });
-+
-+ CodeSource cs = null;
-+ URL url = null;
-+ if(pd != null)
-+ cs = pd.getCodeSource();
-+ if(cs != null)
-+ url = cs.getLocation();
-+
-+ domains[0] = getJSProtectionDomain(url, targetObj.getClass());
-+ return new AccessControlContext(domains);
-+ }catch(Exception exc) {
-+ Trace.liveConnectPrintException(exc);
-+ }
-+
-+ return null;
-+ }
-+
-+ /**
-+ * Invoke a method according to the method index.
-+ *
-+ * @param flag Invoke flag
-+ * @param index Method index
-+ * @param params Arguments.
-+ * @return Java object.
-+ */
-+ public Object invokeImpl(int flag, int index, Object []params)
- throws Exception
- {
- Object retObj = null;
- Dispatcher disp = null;
- try {
-- convertParams(params);
-+ if(params != null)
-+ convertParams(params);
- disp = targetClass.getDispatcher(flag, index, params);
-- return disp.invoke(targetObj, params);
-- }
-- catch (Throwable e)
-- {
-- //e.printStackTrace();
-+ if(disp != null) {
-+ retObj = disp.invoke(targetObj, params);
-+ if(retObj != null)
-+ retObj = Utils.convertReturn(disp.getReturnType(), retObj, handle);
-+ }
-+ return retObj;
-+ } catch (Throwable e) {
- Throwable cause = e.getCause();
- if(cause == null) {
- cause = e;
-@@ -82,11 +179,39 @@
- return targetClass;
- }
-
-+ public int getReturnType(int id){
-+ return targetClass.getReturnType(id);
-+ }
-+
-+ public int getIdForName(final String name) throws Exception{
-+ try {
-+ //No security constraints in case of ActiveX bridge application
-+ if(isBridge)
-+ return getIdForNameImpl(name);
-+
-+ if(context == null) {
-+ context = createContext();
-+ }
-+
-+ // Invoke the method within the applet sand box security restricitions
-+ Integer retVal = (Integer)AccessController.doPrivileged(
-+ new PrivilegedExceptionAction() {
-+ public Object run() throws Exception{
-+ return new Integer(getIdForNameImpl(name));
-+ }
-+ }, context
-+ );
-+ return retVal.intValue();
-+ }catch(PrivilegedActionException pe) {
-+ }
-+
-+ return -1;
-+ }
-
- /*
- *
- */
-- public int getIdForName(String name) throws Exception{
-+ public int getIdForNameImpl(String name) throws Exception{
- int id = -1;
-
- if(targetClass == null && targetObj != null) {
-@@ -103,27 +228,122 @@
- }
-
- /*
-- *
-+ * Unwraps the wrapped java object arguments
- */
- private void convertParams(Object []params) {
- for(int i=0;i<params.length;i++) {
- if(params[i] != null && params[i] instanceof DispatchImpl) {
- params[i] = ((DispatchImpl)params[i]).getWrappedObject();
- } else if(params[i] != null && params[i] instanceof DispatchClient){
-- JSObject jsObj = new JSObject((DispatchClient)params[i]);
-- jsObj.setIExplorerAppletContext((IExplorerAppletContext)
-+ JSObject jsObj = null;
-+ if (!isBridge) {
-+ jsObj = new JSObject((DispatchClient)params[i]);
-+ jsObj.setIExplorerAppletContext((IExplorerAppletContext)
- ((Applet)targetObj).getAppletContext());
-+ } else {
-+ jsObj = new JSObject((DispatchClient)params[i], handle);
-+ }
- params[i] = jsObj;
- }
- }
- }
-
-+ /**
-+ * Returns a protection domain that represents the default permission
-+ * for a given URL.
-+ *
-+ * @param urlString URL
-+ * @return protection domain.
-+ */
-+ public static ProtectionDomain getJSProtectionDomain(URL url, Class clazz)
-+ throws MalformedURLException {
-+
-+ // Obtain default java applet policy
-+ Policy policy = (Policy)AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ return Policy.getPolicy();
-+ }
-+ });
-+
-+ CodeSource cs = new CodeSource(null, (java.security.cert.Certificate[])null);
-+ final PermissionCollection pc = policy.getPermissions(cs);
-+ if(url != null) {
-+ Permission p;
-+ String path = null;
-+ try {
-+ p = url.openConnection().getPermission();
-+ } catch (java.io.IOException ioe) {
-+ p = null;
-+ }
-+
-+ if (p instanceof FilePermission) {
-+ path = p.getName();
-+ } else if ((p == null) && (url.getProtocol().equals("file"))) {
-+ path = url.getFile().replace('/', File.separatorChar);
-+ path = ParseUtil.decode(path);
-+ } else if (p instanceof SocketPermission) {
-+ /*
-+ Socket permission to connect back to the host
-+ */
-+ String host = url.getHost();
-+ pc.add(new SocketPermission(host,
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ }
-+
-+ if(path != null &&
-+ (clazz.getClassLoader() instanceof PluginClassLoader)) {
-+ //We need to add an additional permission to read recursively
-+ if (path.endsWith(File.separator)) {
-+ path += "-";
-+ } else {
-+ int endIndex = path.lastIndexOf(File.separatorChar);
-+ if (endIndex != -1)
-+ path = path.substring(0, endIndex+1) + "-";
-+ }
-+
-+ pc.add(new FilePermission(path, SecurityConstants.FILE_READ_ACTION));
-+
-+ /*
-+ Socket permission to connect back to the "localhost"
-+ */
-+ pc.add(new SocketPermission("localhost",
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ AccessController.doPrivileged(new PrivilegedAction() {
-+ public Object run() {
-+ try {
-+ String host = InetAddress.getLocalHost().getHostName();
-+ pc.add(new SocketPermission(host,
-+ SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION));
-+ } catch (UnknownHostException uhe) {
-+ }
-+ return null;
-+ }
-+ });
-+ }
-+ }
-+
-+ return new JavaScriptProtectionDomain(pc);
-+ }
-+
- public String toString() {
- if(targetObj != null) {
- return targetObj.toString();
- }
- return null;
- }
-+
-+ public int getWindowHandle() {
-+ if(wndHandle == 0) {
-+ wndHandle = getWindowHandle(handle);
-+ }
-+ return wndHandle;
-+ }
-+
-+ protected void setBridge() {
-+ isBridge = true;
-+ }
-+
-+ native int getWindowHandle(int id);
- }
-
-
diff --git a/java/jdk16/files/patch-plugin_FileList.gmk b/java/jdk16/files/patch-plugin_FileList.gmk
deleted file mode 100644
index c5fca27bdda9..000000000000
--- a/java/jdk16/files/patch-plugin_FileList.gmk
+++ /dev/null
@@ -1,22 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/make/plugin/java/FileList.gmk 7 Nov 2003 12:15:52 -0000 1.2
-+++ ../../deploy/make/plugin/java/FileList.gmk 3 Dec 2004 03:56:58 -0000 1.3
-@@ -86,6 +86,9 @@
- \
- sun/plugin/javascript/JSObject.java \
- sun/plugin/javascript/JSContext.java \
-+ sun/plugin/javascript/JSClassLoader.java \
-+ sun/plugin/javascript/ReflectUtil.java \
-+ sun/plugin/javascript/JSInvoke.java \
- \
- sun/plugin/javascript/navig/Navigator.java \
- sun/plugin/javascript/navig/Document.java \
-@@ -125,6 +128,7 @@
- sun/plugin/liveconnect/JavaScriptPermission.java \
- sun/plugin/liveconnect/SecurityContextHelper.java \
- sun/plugin/liveconnect/LiveConnect.java \
-+ sun/plugin/liveconnect/ReplaceMethod.java \
- \
- sun/plugin/extension/ExtensionInstallationImpl.java \
- sun/plugin/extension/ExtensionInstaller.java \
diff --git a/java/jdk16/files/patch-plugin_MethodDispatcher.java b/java/jdk16/files/patch-plugin_MethodDispatcher.java
deleted file mode 100644
index 57e6d22b5a63..000000000000
--- a/java/jdk16/files/patch-plugin_MethodDispatcher.java
+++ /dev/null
@@ -1,41 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/src/share/classes/sun/plugin/com/MethodDispatcher.java 22 Oct 2003 23:04:20 -0000 1.1
-+++ ../../deploy/src/plugin/src/share/classes/sun/plugin/com/MethodDispatcher.java 3 Dec 2004 03:56:58 -0000 1.2
-@@ -1,7 +1,7 @@
- /*
-- * @(#)MethodDispatcher.java 1.5 03/01/23
-+ * @(#)MethodDispatcher.java 1.10 04/06/20
- *
-- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
-+ * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
- * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
- */
-
-@@ -9,6 +9,7 @@
-
- import java.lang.reflect.Method;
- import sun.plugin.util.Trace;
-+import sun.plugin.javascript.JSClassLoader;
-
- /**
- * A <code>MethodDispatcher</code> provides information about,
-@@ -47,11 +48,16 @@
- Object retObj = null;
- if(method != null && obj != null) {
- Trace.msgLiveConnectPrintln("com.method.invoke", new Object[] {method});
-+ Class theClass = obj.getClass();
- Object[] params = TypeConverter.convertObjectArray(
- method.getParameterTypes(), args);
-- retObj = Utils.convertReturn( method.getReturnType(),
-- method.invoke(obj, params ));
-+ // check if the class is private and the method is public
-+ retObj = JSClassLoader.invoke(method, obj, params);
- }
- return retObj;
-+ }
-+
-+ public Class getReturnType() {
-+ return method.getReturnType();
- }
- }
diff --git a/java/jdk16/files/patch-plugin_ns600_nscore.h b/java/jdk16/files/patch-plugin_ns600_nscore.h
deleted file mode 100644
index 9e4bcacf650a..000000000000
--- a/java/jdk16/files/patch-plugin_ns600_nscore.h
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns600/nscore.h.orig Fri Jul 30 18:00:04 2004
-+++ ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns600/nscore.h Fri Jul 30 23:32:31 2004
-@@ -163,7 +163,7 @@
- */
-
- /* under Metrowerks (Mac), we don't have autoconf yet */
--#ifdef __MWERKS__
-+#if defined(__MWERKS__) || defined(NS_UNIX)
- #define HAVE_CPP_SPECIALIZATION
- #define HAVE_CPP_PARTIAL_SPECIALIZATION
- #define HAVE_CPP_MODERN_SPECIALIZE_TEMPLATE_SYNTAX
diff --git a/java/jdk16/files/patch-plugin_ns610_nscore.h b/java/jdk16/files/patch-plugin_ns610_nscore.h
deleted file mode 100644
index de8cc76e5fa3..000000000000
--- a/java/jdk16/files/patch-plugin_ns610_nscore.h
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns610/nscore.h.orig Fri Jul 30 18:00:05 2004
-+++ ../../deploy/src/plugin/oji-plugin/include/mozilla_headers_ns610/nscore.h Fri Jul 30 23:23:36 2004
-@@ -163,7 +163,7 @@
- */
-
- /* under Metrowerks (Mac), we don't have autoconf yet */
--#ifdef __MWERKS__
-+#if defined(__MWERKS__) || defined(NS_UNIX)
- #define HAVE_CPP_SPECIALIZATION
- #define HAVE_CPP_PARTIAL_SPECIALIZATION
- #define HAVE_CPP_MODERN_SPECIALIZE_TEMPLATE_SYNTAX
diff --git a/java/jdk16/files/patch-vm::os_bsd.hpp b/java/jdk16/files/patch-vm::os_bsd.hpp
deleted file mode 100644
index cab94f46e4d3..000000000000
--- a/java/jdk16/files/patch-vm::os_bsd.hpp
+++ /dev/null
@@ -1,13 +0,0 @@
-$FreeBSD$
-
---- ../../hotspot/src/os/bsd/vm/os_bsd.hpp.orig Wed Oct 20 16:01:08 2004
-+++ ../../hotspot/src/os/bsd/vm/os_bsd.hpp Wed Oct 20 16:01:30 2004
-@@ -353,7 +353,7 @@
- bool trylock() {
- verify();
- int status = pthread_mutex_trylock(_mutex);
-- if (status == EBUSY)
-+ if (status == EBUSY || status == EDEADLK)
- return false;
- assert(status == 0, "pthread_mutex_trylock");
- #ifndef PRODUCT
diff --git a/java/jdk16/pkg-plist b/java/jdk16/pkg-plist
index 32bbfdbb4198..901429fa23fb 100644
--- a/java/jdk16/pkg-plist
+++ b/java/jdk16/pkg-plist
@@ -893,6 +893,7 @@ jdk%%JDK_VERSION%%/jre/Welcome.html
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/bin/ControlPanel
jdk%%JDK_VERSION%%/jre/bin/java
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/bin/java_vm
+%%MINIMAL:%%%%DEBUG:%%jdk%%JDK_VERSION%%/jre/bin/java_vm_g
jdk%%JDK_VERSION%%/jre/bin/keytool
jdk%%JDK_VERSION%%/jre/bin/kinit
jdk%%JDK_VERSION%%/jre/bin/klist
@@ -980,6 +981,7 @@ jdk%%JDK_VERSION%%/jre/lib/i386/libioser12.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjaas_unix.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjava.so
%%MINIMAL:%%jdk%%JDK_VERSION%%/jre/lib/i386/libjavaplugin_jni.so
+%%MINIMAL:%%%%DEBUG:%%jdk%%JDK_VERSION%%/jre/lib/i386/libjavaplugin_jni_g.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjawt.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjcov.so
jdk%%JDK_VERSION%%/jre/lib/i386/libjdwp.so