harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hinde...@apache.org
Subject svn commit: r783825 [1/2] - in /harmony/enhanced/classlib/branches/java6: ./ depends/build/platform/ depends/files/ make/ modules/archive/src/main/native/archive/shared/ modules/auth/src/main/native/auth/shared/ modules/auth/src/main/native/auth/window...
Date Thu, 11 Jun 2009 16:05:20 GMT
Author: hindessm
Date: Thu Jun 11 16:05:16 2009
New Revision: 783825

URL: http://svn.apache.org/viewvc?rev=783825&view=rev
Log:
Merge updates from classlib trunk@782693 since r772828.

Added:
    harmony/enhanced/classlib/branches/java6/modules/luni/make/exclude.zos.s390.ibm
      - copied unchanged from r782693, harmony/enhanced/classlib/trunk/modules/luni/make/exclude.zos.s390.ibm
    harmony/enhanced/classlib/branches/java6/modules/luni/make/exclude.zos.s390x.ibm
      - copied unchanged from r782693, harmony/enhanced/classlib/trunk/modules/luni/make/exclude.zos.s390x.ibm
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/macosx/
      - copied from r782693, harmony/enhanced/classlib/trunk/modules/luni/src/main/native/luni/unix/macosx/
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/macosx/OSResourcesMonitor.c
      - copied unchanged from r782693, harmony/enhanced/classlib/trunk/modules/luni/src/main/native/luni/unix/macosx/OSResourcesMonitor.c
    harmony/enhanced/classlib/branches/java6/modules/nio/make/exclude.zos.s390.ibm
      - copied unchanged from r782693, harmony/enhanced/classlib/trunk/modules/nio/make/exclude.zos.s390.ibm
    harmony/enhanced/classlib/branches/java6/modules/nio/make/exclude.zos.s390x.ibm
      - copied unchanged from r782693, harmony/enhanced/classlib/trunk/modules/nio/make/exclude.zos.s390x.ibm
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/port/unix/macosx/
      - copied from r782693, harmony/enhanced/classlib/trunk/modules/portlib/src/main/native/port/unix/macosx/
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/port/unix/macosx/hymmap.c
      - copied unchanged from r782693, harmony/enhanced/classlib/trunk/modules/portlib/src/main/native/port/unix/macosx/hymmap.c
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/port/unix/macosx/hysl.c
      - copied unchanged from r782693, harmony/enhanced/classlib/trunk/modules/portlib/src/main/native/port/unix/macosx/hysl.c
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/port/unix/macosx/hyvmem.c
      - copied unchanged from r782693, harmony/enhanced/classlib/trunk/modules/portlib/src/main/native/port/unix/macosx/hyvmem.c
Removed:
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/org/apache/harmony/luni/util/Version.java
Modified:
    harmony/enhanced/classlib/branches/java6/   (props changed)
    harmony/enhanced/classlib/branches/java6/NOTICE
    harmony/enhanced/classlib/branches/java6/depends/build/platform/macosx.x86.mk
    harmony/enhanced/classlib/branches/java6/depends/files/bootclasspath.properties
    harmony/enhanced/classlib/branches/java6/make/build-java.xml
    harmony/enhanced/classlib/branches/java6/make/build-test.xml
    harmony/enhanced/classlib/branches/java6/make/depends-common.xml   (props changed)
    harmony/enhanced/classlib/branches/java6/make/run-test.xml
    harmony/enhanced/classlib/branches/java6/modules/archive/src/main/native/archive/shared/archive_copyright.c
    harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/shared/auth_copyright.c
    harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/fontlib/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/gl/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/jpegdecoder/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/lcmm/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/linuxfont/unix/LinuxNativeFont.c
    harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/oglwrapper/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/win32wrapper/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/winfont/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/PropertyChangeSupport.java
    harmony/enhanced/classlib/branches/java6/modules/concurrent/src/main/java/java/util/concurrent/atomic/   (props changed)
    harmony/enhanced/classlib/branches/java6/modules/concurrent/src/main/java/java/util/concurrent/locks/   (props changed)
    harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/jpegencoder/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/pngencoder/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/instrument/src/main/native/instrument/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/jmx/META-INF/   (props changed)
    harmony/enhanced/classlib/branches/java6/modules/lang-management/src/test/api/java/org/apache/harmony/lang/management/tests/java/util/logging/   (props changed)
    harmony/enhanced/classlib/branches/java6/modules/logging/build.xml
    harmony/enhanced/classlib/branches/java6/modules/luni/build.xml
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/AbstractStringBuilder.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Double.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Float.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URL.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URLClassLoader.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Arrays.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Hashtable.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/IdentityHashMap.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSFileSystem.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/fdlibm/unix/makefile
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/launcher_copyright.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/main.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/unix/main_hlp.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/cbigint.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/dblparse.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/fltparse.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/luni_copyright.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSFileSystemLinux32.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSMemoryLinux32.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/helpers.c
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/io/FileTest.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/lang/StringBuilderTest.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/URLClassLoaderTest.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/HashtableTest.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMap2Test.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMapTest.java
    harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/shared/MemMacros.h
    harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/nio/src/main/java/common/java/nio/CharBuffer.java
    harmony/enhanced/classlib/branches/java6/modules/nio/src/main/java/common/org/apache/harmony/nio/internal/SelectorImpl.java
    harmony/enhanced/classlib/branches/java6/modules/nio/src/main/java/common/org/apache/harmony/nio/internal/ServerSocketChannelImpl.java
    harmony/enhanced/classlib/branches/java6/modules/nio/src/main/native/nio/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/CharBufferTest.java
    harmony/enhanced/classlib/branches/java6/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/FileChannelTest.java
    harmony/enhanced/classlib/branches/java6/modules/nio_char/src/test/java/tests/api/java/nio/charset/CharsetDecoderTest.java
    harmony/enhanced/classlib/branches/java6/modules/nio_char/src/test/java/tests/api/java/nio/charset/CharsetTest.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/BHSDCodec.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/BcBands.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/CPMethodOrField.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/CPNameAndType.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/ClassBands.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/CpBands.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/FileBands.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/Segment.java
    harmony/enhanced/classlib/branches/java6/modules/pack200/src/main/java/org/apache/harmony/pack200/SegmentHeader.java
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/port/shared/port_copyright.c
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/port/unix/hysock.c
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/port/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/thread/shared/thread_copyright.c
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/thread/unix/thrdsup.h
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/thread/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/portlib/src/main/native/thrstub/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/prefs/src/main/native/prefs/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/prefs/src/main/native/prefs/windows/prefs_copyright.c
    harmony/enhanced/classlib/branches/java6/modules/print/src/main/native/print/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/security/src/main/native/security/shared/security_copyright.c
    harmony/enhanced/classlib/branches/java6/modules/security/src/main/native/security/windows/makefile
    harmony/enhanced/classlib/branches/java6/modules/security/src/test/impl/java/org/apache/harmony/security/tests/provider/crypto/SHA1ImplTest.java
    harmony/enhanced/classlib/branches/java6/modules/security/src/test/support/common/java/org/apache/harmony/security/tests/support/provider/cert/CertFactoryTestData.java
    harmony/enhanced/classlib/branches/java6/modules/swing/src/test/api/java.injected/javax/swing/BasicSwingTestCase.java   (props changed)
    harmony/enhanced/classlib/branches/java6/modules/swing/src/test/api/java.injected/javax/swing/SwingTestCase.java   (props changed)
    harmony/enhanced/classlib/branches/java6/modules/swing/src/test/api/java.injected/javax/swing/text/parser/   (props changed)

Propchange: harmony/enhanced/classlib/branches/java6/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Jun 11 16:05:16 2009
@@ -1 +1 @@
-/harmony/enhanced/classlib/trunk:713674-735919,765923-772828
+/harmony/enhanced/classlib/trunk:713674-735919,765923-782693

Modified: harmony/enhanced/classlib/branches/java6/NOTICE
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/NOTICE?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/NOTICE (original)
+++ harmony/enhanced/classlib/branches/java6/NOTICE Thu Jun 11 16:05:16 2009
@@ -4,7 +4,7 @@
 This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).
 
-Portions of Harmony were originally developed by
+Portions of Apache Harmony were originally developed by
 Intel Corporation and are licensed to the Apache Software
 Foundation under the "Software Grant and Corporate Contribution
 License Agreement" and for which the following copyright notices
@@ -12,3 +12,7 @@
          (C) Copyright 2005 Intel Corporation
          (C) Copyright 2005-2006 Intel Corporation
          (C) Copyright 2006 Intel Corporation
+
+Portions of Apache Harmony's Class Library TEXT module contain JavaDoc
+derived from the ICU project.
+Copyright (c) 1995-2008 International Business Machines Corporation and others 

Modified: harmony/enhanced/classlib/branches/java6/depends/build/platform/macosx.x86.mk
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/depends/build/platform/macosx.x86.mk?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/depends/build/platform/macosx.x86.mk (original)
+++ harmony/enhanced/classlib/branches/java6/depends/build/platform/macosx.x86.mk Thu Jun 11 16:05:16 2009
@@ -14,10 +14,13 @@
 #  limitations under the License.
 
 DEFINES += -DMACOSX -DMACOSX_X86 -DHYX86 -DIPv6_FUNCTION_SUPPORT
+
+# Add the default location of the macports.org install to the includes
+INCLUDES += -I/opt/local/include
 OPT += -fPIC -fno-common
-OSLIBS = -lc -lm -ldl -liconv
+OSLIBS = -L/opt/local/lib -lc -lm -ldl -liconv
 XLIBS = -L/usr/X11R6/lib -lX11 -lXft -lXext -lXtst -lXrender -lexpat \
-        -L/sw/lib/freetype2/lib -lfreetype -lfontconfig
+        -lfreetype -lfontconfig
 MDLLIBPREFIX =
 MDLLIBSUFFIX =
 EXERPATHPREFIX = 

Modified: harmony/enhanced/classlib/branches/java6/depends/files/bootclasspath.properties
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/depends/files/bootclasspath.properties?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/depends/files/bootclasspath.properties (original)
+++ harmony/enhanced/classlib/branches/java6/depends/files/bootclasspath.properties Thu Jun 11 16:05:16 2009
@@ -111,10 +111,6 @@
 bootclasspath.source.17=nio_char-src.jar
 bootclasspath.source.packageroot.17=/
 
-bootclasspath.18=orb.jar
-bootclasspath.source.18=orb-src.jar
-bootclasspath.source.packageroot.18=/
-
 bootclasspath.19=prefs.jar
 bootclasspath.source.19=prefs-src.jar
 bootclasspath.source.packageroot.19=/

Modified: harmony/enhanced/classlib/branches/java6/make/build-java.xml
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/make/build-java.xml?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/make/build-java.xml (original)
+++ harmony/enhanced/classlib/branches/java6/make/build-java.xml Thu Jun 11 16:05:16 2009
@@ -215,11 +215,6 @@
             <fileset file="${bcprov.jar}" />
         </copy>
 
-        <!-- Copy across the jdk/lib dependency jars -->
-        <copy todir="${hy.jdk}/lib" flatten="yes">
-            <fileset file="${ecj.jar}" />
-        </copy>
-
         <!-- Copy across the support files -->
         <copy todir="${hy.jdk}/jre/lib">
             <fileset dir="${depends.files}">

Modified: harmony/enhanced/classlib/branches/java6/make/build-test.xml
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/make/build-test.xml?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/make/build-test.xml (original)
+++ harmony/enhanced/classlib/branches/java6/make/build-test.xml Thu Jun 11 16:05:16 2009
@@ -21,14 +21,15 @@
 
     <description> Tests for classlib package</description>
 
+    <property name="hy.hdk" location="deploy" />
+    <property name="hy.jdk" location="${hy.hdk}/jdk" />
+
     <!-- import common properties -->
     <import file="${basedir}/make/properties.xml" />
 
     <!-- set global properties for this build. -->
 
     <property name="tests.output" location="build/test_report" />
-    <property name="hy.hdk" location="deploy" />
-    <property name="hy.jdk" location="${hy.hdk}/jdk" />
 
     <property name="tests.build.output" location="build/tests" />
     <property name="tests.support.output" location="build/test_support" />
@@ -96,6 +97,7 @@
         <jar destfile="${hy.hdk}/build/test/support.jar"
              manifest="support/META-INF/MANIFEST.MF">
             <fileset dir="${tests.support.output}" />
+            <metainf refid="hy.required.metainf-files"/>
         </jar>
         <copy todir="${hy.hdk}/build/test"> 
         <fileset dir="${jetty.dir}">
@@ -155,6 +157,8 @@
             </fileset>
             <fileset file="${support.dir}/src/test/resources/hyts_Foo.c"/>
         </copy>
+        <copy file="${support.dir}/src/test/resources/config/testing.policy" 
+              todir="${hy.hdk}/build/test" outputencoding="UTF-8" />
     </target>
 
     <target name="check-support-jars"
@@ -182,7 +186,7 @@
             
 
             <!-- Required by various tests that set security manager etc -->
-            <jvmarg value="-Djava.security.policy=${support.dir}/src/test/resources/config/testing.policy" />
+            <jvmarg value="-Djava.security.policy=${hy.hdk}/build/test/testing.policy" />
 
             <!-- Required for running the java.net unit tests -->
             <jvmarg value="-Dtest.ini.file=${support.dir}/src/test/resources/config/localhosttest.ini" />
@@ -223,7 +227,7 @@
             <!-- required to be unset on Linux -->
 
             <!-- Required by various tests that set security manager etc -->
-            <jvmarg value="-Djava.security.policy=${support.dir}/src/test/resources/config/testing.policy" />
+            <jvmarg value="-Djava.security.policy=${hy.hdk}/build/test/testing.policy" />
 
             <!-- Required for running the java.net unit tests -->
             <jvmarg value="-Dtest.ini.file=${support.dir}/src/test/resources/config/localhosttest.ini" />

Propchange: harmony/enhanced/classlib/branches/java6/make/depends-common.xml
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Jun 11 16:05:16 2009
@@ -1 +1 @@
-/harmony/enhanced/classlib/trunk/make/depends-common.xml:768152-772828
+/harmony/enhanced/classlib/trunk/make/depends-common.xml:768152-782693

Modified: harmony/enhanced/classlib/branches/java6/make/run-test.xml
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/make/run-test.xml?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/make/run-test.xml (original)
+++ harmony/enhanced/classlib/branches/java6/make/run-test.xml Thu Jun 11 16:05:16 2009
@@ -55,7 +55,7 @@
         <run-tests module="luni" jar="luni_tests_api.jar">
             <junit-elements>
                 <!-- Required by various tests that set security manager etc -->
-                <jvmarg value="-Djava.security.policy=${target.dir}/luni/resources/config/testing.policy" />
+                <jvmarg value="-Djava.security.policy=${hy.hdk}/build/test/testing.policy" />
 
                 <!-- Required for running the java.net unit tests -->
                 <jvmarg value="-Dtest.ini.file=${target.dir}/luni/resources/config/localhosttest.ini" />
@@ -65,7 +65,7 @@
         <run-tests module="luni" jar="luni_tests_impl.jar">
             <junit-elements>
                 <!-- Required by various tests that set security manager etc -->
-                <jvmarg value="-Djava.security.policy=${target.dir}/luni/resources/config/testing.policy" />
+                <jvmarg value="-Djava.security.policy=${hy.hdk}/build/test/testing.policy" />
 
                 <!-- Required for running the java.net unit tests -->
                 <jvmarg value="-Dtest.ini.file=${target.dir}/luni/resources/config/localhosttest.ini" />

Modified: harmony/enhanced/classlib/branches/java6/modules/archive/src/main/native/archive/shared/archive_copyright.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/archive/src/main/native/archive/shared/archive_copyright.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/archive/src/main/native/archive/shared/archive_copyright.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/archive/src/main/native/archive/shared/archive_copyright.c Thu Jun 11 16:05:16 2009
@@ -18,5 +18,5 @@
 /* A copyright string included in each DLL and executable */
 
 const char hyCopyright[] =
-  "(c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as applicable.";
+  "(c) Copyright 1991, 2008 The Apache Software Foundation or its licensors, as applicable.";
 

Modified: harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/shared/auth_copyright.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/shared/auth_copyright.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/shared/auth_copyright.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/shared/auth_copyright.c Thu Jun 11 16:05:16 2009
@@ -18,4 +18,4 @@
 /* A copyright string included in each DLL and executable */
 
 const char hyCopyright[] =
-  "(c) Copyright 2005, 2006 The Apache Software Foundation or its licensors, as applicable.";
+  "(c) Copyright 2005, 2007 The Apache Software Foundation or its licensors, as applicable.";

Modified: harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/auth/src/main/native/auth/windows/makefile Thu Jun 11 16:05:16 2009
@@ -36,6 +36,6 @@
 MDLLIBFILES = $(MDLLIBFILES) $(LIBPATH)hypool$(HY_LINKLIB_SUFFIX) \
 	$(LIBPATH)hyfdlibm$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX)
 DLLBASE=0x1300000
-COMMENT=/comment:"Auth component native code. (c) Copyright 2005, 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"Auth component native code. (c) Copyright 2005, 2007 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/fontlib/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/fontlib/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/fontlib/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/fontlib/windows/makefile Thu Jun 11 16:05:16 2009
@@ -46,6 +46,6 @@
   $(LIBPATH)hyzlib.lib 
 
 DLLBASE=0x13300000
-COMMENT=/comment:"FontLib native code. (c) Copyright 2005 - 2007 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"FontLib native code. (c) Copyright 2005, 2007 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/gl/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/gl/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/gl/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/gl/windows/makefile Thu Jun 11 16:05:16 2009
@@ -49,6 +49,6 @@
   $(LIBPATH)hyzlib$(HY_LINKLIB_SUFFIX) $(PNG_DIR)libpng$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13300000
-COMMENT=/comment:"GL native code. (c) Copyright 2005 - 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"GL native code. (c) Copyright 2005, 2008 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/jpegdecoder/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/jpegdecoder/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/jpegdecoder/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/jpegdecoder/windows/makefile Thu Jun 11 16:05:16 2009
@@ -33,7 +33,7 @@
   $(LIBPATH)hypool$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX) $(JPEG_DIR)libjpeg$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13300000
-COMMENT=/comment:"JPEGDECODER native code. (c) Copyright 2005 - 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"JPEGDECODER native code. (c) Copyright 2005, 2007 The Apache Software Foundation or its licensors, as applicable."
 
 CLEANFILES=jconfig.h
 

Modified: harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/lcmm/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/lcmm/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/lcmm/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/lcmm/windows/makefile Thu Jun 11 16:05:16 2009
@@ -38,6 +38,6 @@
   $(LIBPATH)hypool$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX) $(LCMS_DIR)lcms114$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13300000
-COMMENT=/comment:"LCMM Wrapper native code. (c) Copyright 2005 - 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"LCMM Wrapper native code. (c) Copyright 2005, 2007 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/linuxfont/unix/LinuxNativeFont.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/linuxfont/unix/LinuxNativeFont.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/linuxfont/unix/LinuxNativeFont.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/linuxfont/unix/LinuxNativeFont.c Thu Jun 11 16:05:16 2009
@@ -115,7 +115,7 @@
         for (j = 0; j < numFamilies; j++) {
 
 #ifdef DEBUG
-            font = FcNameUnparse (fs->fonts[j]);
+            FcChar8* font = FcNameUnparse (fs->fonts[j]);
             printf ("%s\n", font);
             free (font);
 #endif /* DEBUG */
@@ -910,9 +910,11 @@
             }
 
 #ifdef DEBUG
-            font = FcNameUnparse (fs->fonts[j]);
-            printf ("%s\n", font);
-            free(font);
+            {
+             FcChar8* font = FcNameUnparse (fs->fonts[j]);
+             printf ("%s\n", font);
+             free(font);
+            }
 #endif /* DEBUG */
 
             if (XftPatternGetString (fs->fonts[j], XFT_STYLE, 0, &style) != XftResultMatch) {

Modified: harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/oglwrapper/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/oglwrapper/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/oglwrapper/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/oglwrapper/windows/makefile Thu Jun 11 16:05:16 2009
@@ -30,6 +30,6 @@
 MDLLIBFILES = $(MDLLIBFILES) $(LIBPATH)hypool$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13300000
-COMMENT=/comment:"OpenGL Wrapper native code. (c) Copyright 2005 - 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"OpenGL Wrapper native code. (c) Copyright 2005, 2006 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/win32wrapper/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/win32wrapper/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/win32wrapper/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/win32wrapper/windows/makefile Thu Jun 11 16:05:16 2009
@@ -34,6 +34,6 @@
 MDLLIBFILES = $(MDLLIBFILES) $(LIBPATH)hypool$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX) 
 
 DLLBASE=0x13300000
-COMMENT=/comment:"Win32 Wrapper native code. (c) Copyright 2005 - 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"Win32 Wrapper native code. (c) Copyright 2005, 2006 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/winfont/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/winfont/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/winfont/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/awt/src/main/native/winfont/windows/makefile Thu Jun 11 16:05:16 2009
@@ -33,6 +33,6 @@
 MDLLIBFILES = $(MDLLIBFILES) $(LIBPATH)hypool$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX) $(LIBPATH)FL$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13300000
-COMMENT=/comment:"Win32 Font native code. (c) Copyright 2005 - 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"Win32 Font native code. (c) Copyright 2005, 2007 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/PropertyChangeSupport.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/PropertyChangeSupport.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/PropertyChangeSupport.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/PropertyChangeSupport.java Thu Jun 11 16:05:16 2009
@@ -256,8 +256,11 @@
         }
 
         // Collect up the global listeners
-        PropertyChangeListener[] gListeners = globalListeners
-                .toArray(new PropertyChangeListener[0]);
+        PropertyChangeListener[] gListeners;
+        synchronized(this) {
+            gListeners = globalListeners.toArray(new PropertyChangeListener[0]);
+        }
+
         // Fire the events for global listeners
         for (int i = 0; i < gListeners.length; i++) {
             gListeners[i].propertyChange(event);

Propchange: harmony/enhanced/classlib/branches/java6/modules/concurrent/src/main/java/java/util/concurrent/atomic/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Jun 11 16:05:16 2009
@@ -1 +1 @@
-/harmony/enhanced/classlib/trunk/modules/concurrent/src/main/java/java/util/concurrent/atomic:765923-772828
+/harmony/enhanced/classlib/trunk/modules/concurrent/src/main/java/java/util/concurrent/atomic:765923-782693

Propchange: harmony/enhanced/classlib/branches/java6/modules/concurrent/src/main/java/java/util/concurrent/locks/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Jun 11 16:05:16 2009
@@ -1 +1 @@
-/harmony/enhanced/classlib/trunk/modules/concurrent/src/main/java/java/util/concurrent/locks:765923-772828
+/harmony/enhanced/classlib/trunk/modules/concurrent/src/main/java/java/util/concurrent/locks:765923-782693

Modified: harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/jpegencoder/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/jpegencoder/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/jpegencoder/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/jpegencoder/windows/makefile Thu Jun 11 16:05:16 2009
@@ -44,7 +44,7 @@
   $(LIBPATH)hypool$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX) $(JPEG_DIR)libjpeg$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13300000
-COMMENT=/comment:"JPEGENCODER native code. (c) Copyright 2005 - 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"JPEGENCODER native code. (c) Copyright 2005, 2008 The Apache Software Foundation or its licensors, as applicable."
 
 CLEANFILES=jconfig.h
 

Modified: harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/pngencoder/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/pngencoder/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/pngencoder/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/imageio/src/main/native/pngencoder/windows/makefile Thu Jun 11 16:05:16 2009
@@ -35,6 +35,6 @@
   $(LIBPATH)hyzlib$(HY_LINKLIB_SUFFIX) $(PNG_DIR)libpng$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13300000
-COMMENT=/comment:"PNGENCODER native code. (c) Copyright 2005 - 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"PNGENCODER native code. (c) Copyright 2005, 2008 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/instrument/src/main/native/instrument/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/instrument/src/main/native/instrument/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/instrument/src/main/native/instrument/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/instrument/src/main/native/instrument/windows/makefile Thu Jun 11 16:05:16 2009
@@ -40,6 +40,6 @@
   $(LIBPATH)hyfdlibm$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13200000
-COMMENT=/comment:"instrument component native code. (c) Copyright 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"instrument component native code. (c) Copyright 2006, 2008 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Propchange: harmony/enhanced/classlib/branches/java6/modules/jmx/META-INF/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Jun 11 16:05:16 2009
@@ -1 +1 @@
-/harmony/enhanced/classlib/trunk/modules/jmx/META-INF:768152-772828
+/harmony/enhanced/classlib/trunk/modules/jmx/META-INF:768152-782693

Propchange: harmony/enhanced/classlib/branches/java6/modules/lang-management/src/test/api/java/org/apache/harmony/lang/management/tests/java/util/logging/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Jun 11 16:05:16 2009
@@ -1 +1 @@
-/harmony/enhanced/classlib/trunk/modules/lang-management/src/test/api/java/org/apache/harmony/lang/management/tests/java/util/logging:768152-772828
+/harmony/enhanced/classlib/trunk/modules/lang-management/src/test/api/java/org/apache/harmony/lang/management/tests/java/util/logging:768152-782693

Modified: harmony/enhanced/classlib/branches/java6/modules/logging/build.xml
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/logging/build.xml?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/logging/build.xml (original)
+++ harmony/enhanced/classlib/branches/java6/modules/logging/build.xml Thu Jun 11 16:05:16 2009
@@ -168,6 +168,9 @@
 
         <property name="test.jre.home" value="${hy.jdk}/jre" />
 
+        <copy file="../../support/src/test/resources/config/testing.policy" 
+              todir="${hy.hdk}/build/test" outputencoding="UTF-8" />
+
         <junit fork="yes"
                forkmode="${hy.test.forkmode}"
                timeout="${hy.test.timeout}"
@@ -187,7 +190,7 @@
             <jvmarg value="-Dhy.test.vmargs=${hy.test.vmargs}" />
 
         	<!-- Required by various tests that set security manager etc -->
-            <jvmarg value="-Djava.security.policy=../../support/src/test/resources/config/testing.policy" />
+            <jvmarg value="-Djava.security.policy=${hy.hdk}/build/test/testing.policy" />
 
             <jvmarg value="-Xbootclasspath/a:${hy.logging.bin.internal}"/>
 

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/build.xml
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/build.xml?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/build.xml (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/build.xml Thu Jun 11 16:05:16 2009
@@ -320,7 +320,7 @@
 
         <mkdir dir="${tests.resources.hdk.dir}/config"/>
         <copy file="../../support/src/test/resources/config/testing.policy"
-              todir="${tests.resources.hdk.dir}/config"/>
+              todir="${hy.hdk}/build/test" outputencoding="UTF-8" />
         <copy file="../../support/src/test/resources/config/localhosttest.ini"
               todir="${tests.resources.hdk.dir}/config"/>
 
@@ -535,7 +535,7 @@
                 <jvmarg value="-Dhy.test.vmargs=${hy.test.vmargs}" />
                 
                 <!-- Required by various tests that set security manager etc -->
-                <jvmarg value="-Djava.security.policy=../../support/src/test/resources/config/testing.policy" />
+                <jvmarg value="-Djava.security.policy=${hy.hdk}/build/test/testing.policy" />
 
                 <!-- Required for running the java.net unit tests -->
                 <jvmarg value="-Dtest.ini.file=../../support/src/test/resources/config/localhosttest.ini" />

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/AbstractStringBuilder.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/AbstractStringBuilder.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/AbstractStringBuilder.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/AbstractStringBuilder.java Thu Jun 11 16:05:16 2009
@@ -91,8 +91,8 @@
     }
 
     private void enlargeBuffer(int min) {
-        int twice = (value.length << 1) + 2;
-        char[] newData = new char[min > twice ? min : twice];
+        int newSize = (value.length >> 1 + value.length) + 2;
+        char[] newData = new char[min > newSize ? min : newSize];
         System.arraycopy(value, 0, newData, 0, count);
         value = newData;
         shared = false;
@@ -205,7 +205,7 @@
             }
             if (end > start) {
                 int length = count - end;
-                if (length > 0) {
+                if (length >= 0) {
                     if (!shared) {
                         System.arraycopy(value, end, value, start, length);
                     } else {
@@ -258,7 +258,8 @@
      */
     public void ensureCapacity(int min) {
         if (min > value.length) {
-            enlargeBuffer(min);
+            int twice = (value.length << 1) + 2;
+            enlargeBuffer(twice > min ? twice : min);
         }
     }
 

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Double.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Double.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Double.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Double.java Thu Jun 11 16:05:16 2009
@@ -377,7 +377,7 @@
             return 0;
         }
 
-        // NaNs are equal to other NaNs and larger than any other float
+        // NaNs are equal to other NaNs and larger than any other double
         if (isNaN(double1)) {
             if (isNaN(double2)) {
                 return 0;
@@ -390,11 +390,9 @@
         // Deal with +0.0 and -0.0
         long d1 = doubleToRawLongBits(double1);
         long d2 = doubleToRawLongBits(double2);
-
-        if (d1 == d2) {
-            return 0;
-        }
-        return (d1 < d2) ? -1 : 1;
+        // The below expression is equivalent to:
+        // (d1 == d2) ? 0 : (d1 < d2) ? -1 : 1
+        return (int) ((d1 >> 63) - (d2 >> 63));
     }
 
     /**

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Float.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Float.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Float.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/lang/Float.java Thu Jun 11 16:05:16 2009
@@ -393,11 +393,10 @@
         // Deal with +0.0 and -0.0
         int f1 = floatToRawIntBits(float1);
         int f2 = floatToRawIntBits(float2);
-
-        if (f1 == f2) {
-            return 0;
-        }
-        return (f1 < f2) ? -1 : 1;
+        // The below expression is equivalent to:
+        // (f1 == f2) ? 0 : (f1 < f2) ? -1 : 1
+        // because f1 and f2 are either 0 or Integer.MIN_VALUE
+        return (f1 >> 31) - (f2 >> 31);
     }
 
     /**

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URL.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URL.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URL.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URL.java Thu Jun 11 16:05:16 2009
@@ -493,7 +493,7 @@
      *            the URL this instance has to be compared with.
      * @return {@code true} if both instances represents the same URL, {@code
      *         false} otherwise.
-     * @see #hashCode
+     * @see #hashCode()
      */
     @Override
     public boolean equals(Object o) {

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URLClassLoader.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URLClassLoader.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URLClassLoader.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/net/URLClassLoader.java Thu Jun 11 16:05:16 2009
@@ -1184,9 +1184,9 @@
             String element = tokenizer.nextToken();
             if (!element.equals("")) { //$NON-NLS-1$
                 try {
-                    URL newURL = new URL(protocol, host, port, file + element
-                            + "!/"); //$NON-NLS-1$
-                    addedURLs.add(newURL);
+                    // Take absolute path case into consideration
+                    URL url = new URL(new URL(file), element);
+                    addedURLs.add(createSearchURL(url));
                 } catch (MalformedURLException e) {
                     // Nothing is added
                 }

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Arrays.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Arrays.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Arrays.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Arrays.java Thu Jun 11 16:05:16 2009
@@ -1818,41 +1818,58 @@
     }
 
     private static boolean lessThan(double double1, double double2) {
-        long d1, d2;
-        long NaNbits = Double.doubleToLongBits(Double.NaN);
-        if ((d1 = Double.doubleToLongBits(double1)) == NaNbits) {
+        // A slightly specialized version of
+        // Double.compare(double1, double2) < 0.
+
+        // Non-zero and non-NaN checking.
+        if (double1 < double2) {
+            return true;
+        }
+        if (double1 > double2) {
             return false;
         }
-        if ((d2 = Double.doubleToLongBits(double2)) == NaNbits) {
-            return true;
+        if (double1 == double2 && 0.0d != double1) {
+            return false;
         }
-        if (double1 == double2) {
-            if (d1 == d2) {
-                return false;
-            }
-            // check for -0
-            return d1 < d2;
+
+        // NaNs are equal to other NaNs and larger than any other double.
+        if (Double.isNaN(double1)) {
+            return false;
+        } else if (Double.isNaN(double2)) {
+            return true;
         }
-        return double1 < double2;
+
+        // Deal with +0.0 and -0.0.
+        long d1 = Double.doubleToRawLongBits(double1);
+        long d2 = Double.doubleToRawLongBits(double2);
+        return d1 < d2;
     }
 
     private static boolean lessThan(float float1, float float2) {
-        int f1, f2;
-        int NaNbits = Float.floatToIntBits(Float.NaN);
-        if ((f1 = Float.floatToIntBits(float1)) == NaNbits) {
+        // A slightly specialized version of Float.compare(float1, float2) < 0.
+
+        // Non-zero and non-NaN checking.
+        if (float1 < float2) {
+            return true;
+        }
+        if (float1 > float2) {
             return false;
         }
-        if ((f2 = Float.floatToIntBits(float2)) == NaNbits) {
-            return true;
+        if (float1 == float2 && 0.0f != float1) {
+            return false;
         }
-        if (float1 == float2) {
-            if (f1 == f2) {
-                return false;
-            }
-            // check for -0
-            return f1 < f2;
+
+        // NaNs are equal to other NaNs and larger than any other float
+        if (Float.isNaN(float1)) {
+            return false;
+        } else if (Float.isNaN(float2)) {
+            return true;
         }
-        return float1 < float2;
+
+        // Deal with +0.0 and -0.0
+        int f1 = Float.floatToRawIntBits(float1);
+        int f2 = Float.floatToRawIntBits(float2);
+        return f1 < f2;
     }
 
     private static int med3(byte[] array, int a, int b, int c) {

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Hashtable.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Hashtable.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Hashtable.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/Hashtable.java Thu Jun 11 16:05:16 2009
@@ -542,10 +542,15 @@
         while (it.hasNext()) {
             Map.Entry<K, V> entry = it.next();
             Object key = entry.getKey();
+            if (key == this) {
+                continue;
+            }
             Object value = entry.getValue();
-            int hash = (key != this ? key.hashCode() : 0)
-                    ^ (value != this ? (value != null ? value.hashCode() : 0)
-                            : 0);
+            if (value == this) {
+                continue;
+            }
+            int hash = (key != null ? key.hashCode() : 0)
+                    ^ (value != null ? value.hashCode() : 0);
             result += hash;
         }
         return result;

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/IdentityHashMap.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/IdentityHashMap.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/IdentityHashMap.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/util/IdentityHashMap.java Thu Jun 11 16:05:16 2009
@@ -267,7 +267,10 @@
     }
 
     private int computeElementArraySize() {
-        return (int) (((long) threshold * 10000) / loadFactor) * 2;
+        int arraySize = (int) (((long) threshold * 10000) / loadFactor) * 2;
+        // ensure arraySize is positive, the above cast from long to int type
+        // leads to overflow and negative arraySize if threshold is too big
+        return arraySize < 0 ? -arraySize : arraySize;
     }
 
     /**
@@ -748,7 +751,12 @@
     @Override
     public Object clone() {
         try {
-            return super.clone();
+            IdentityHashMap<K, V> cloneHashMap = (IdentityHashMap<K, V>) super
+                    .clone();
+            cloneHashMap.elementData = newElementArray(elementData.length);
+            System.arraycopy(elementData, 0, cloneHashMap.elementData, 0,
+                    elementData.length);
+            return cloneHashMap;
         } catch (CloneNotSupportedException e) {
             return null;
         }

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSFileSystem.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSFileSystem.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSFileSystem.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSFileSystem.java Thu Jun 11 16:05:16 2009
@@ -20,6 +20,7 @@
 import java.io.FileDescriptor;
 import java.io.FileNotFoundException;
 import java.io.IOException;
+import java.io.UnsupportedEncodingException;
 
 /**
  * This is the portable implementation of the file system interface.
@@ -235,7 +236,14 @@
 		}
 		long handler = openImpl(fileName, mode);
 		if (handler < 0) {
-			throw new FileNotFoundException(new String(fileName));
+                    try {
+                        throw new FileNotFoundException(new String(fileName, "UTF-8"));
+                    } catch (java.io.UnsupportedEncodingException e) {
+                        // UTF-8 should always be supported, so throw an assertion
+                        FileNotFoundException fnfe = new FileNotFoundException(new String(fileName));
+                        e.initCause(fnfe);
+                        throw new AssertionError(e);
+                    }
 		}
 		return handler;
 	}

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/fdlibm/unix/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/fdlibm/unix/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/fdlibm/unix/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/fdlibm/unix/makefile Thu Jun 11 16:05:16 2009
@@ -47,7 +47,7 @@
 # OPT is overriden except on zOS (fpic, for example, is not an option on zOS)
 ifneq ($(HY_OS),zos)
 ifneq ($(HY_OS),aix)
-OPT = -O0 -ffloat-store -fpic
+OPT = -O0 -ffloat-store -fPIC
 endif
 endif
 

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/launcher_copyright.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/launcher_copyright.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/launcher_copyright.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/launcher_copyright.c Thu Jun 11 16:05:16 2009
@@ -18,4 +18,4 @@
 /* A copyright string included in each DLL and executable */
 
 const char hyCopyright[] =
-  "(c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as applicable.";
+  "(c) Copyright 1991, 2009 The Apache Software Foundation or its licensors, as applicable.";

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/main.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/main.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/main.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/shared/main.c Thu Jun 11 16:05:16 2009
@@ -58,7 +58,7 @@
 PROTOTYPE ((HyPortLibrary * portLibrary, int argc, char **argv, UDATA handle,
             jint version, jboolean ignoreUnrecognized, char *mainClass,
             UDATA classArg, char *propertiesFileName,
-            int isStandaloneJar, char *vmdllsubdir, int versionFlag));
+            int isStandaloneJar, char *vmdllsubdir));
 static int createVMArgs
 PROTOTYPE ((HyPortLibrary * portLibrary, int argc, char **argv,
             jint version, jboolean ignoreUnrecognized,
@@ -227,9 +227,8 @@
 			/* The arg is a JAR file to run */
 			isStandaloneJar = 1;
 		}
-		if (0 == strncmp ("-version", argv[i], 8)) {
-            /* Display version information */
-            versionFlag = i;
+		if (0 == strcmp ("-version", argv[i])) {
+            versionFlag = 1;
 		}
 		if (0 == strcmp ("-showversion", argv[i])) {
 			/* We are being asked to print our version and continue */
@@ -364,6 +363,12 @@
         }
     }
     
+  if (versionFlag == 1) {
+    /* 
+     * We are being asked to print our version, and quit 
+     */
+    hyfile_printf (PORTLIB, HYPORT_TTY_OUT, HY_COPYRIGHT_STRING "\n");    
+  }
   /* set up the properties file */
   propertiesFileName = hymem_allocate_memory (strlen (vmiPath) + 12);
   if (propertiesFileName == NULL)
@@ -387,7 +392,7 @@
   /* main launcher processing in this function */
   rc = invocation
       (PORTLIB, argc, argv, handle, JNI_VERSION_1_4, JNI_TRUE, mainClass,
-       classArg, propertiesFileName, isStandaloneJar, vmdllsubdir, versionFlag);
+       classArg, propertiesFileName, isStandaloneJar, vmdllsubdir);
   if (rc)
     {
 	  /* Print an error message except in the case where an uncaught Exception 
@@ -637,7 +642,7 @@
 invocation (HyPortLibrary * portLibrary, int argc, char **argv, UDATA handle,
             jint version, jboolean ignoreUnrecognized, char *mainClass,
             UDATA classArg, char *propertiesFileName,
-            int isStandaloneJar, char *vmdllsubdir, int versionFlag)
+            int isStandaloneJar, char *vmdllsubdir)
 {
   JavaVMInitArgs vm_args;
   JavaVM *jvm;
@@ -673,27 +678,6 @@
     }
 
   rc = 0;
-
-  if (versionFlag) {
-      jclass clazz;
-      jmethodID mID;
-      jstring jStrObject;
-        
-      jStrObject = (*env)->NewStringUTF (env, argv[versionFlag]);
-      if (!jStrObject) return 3;
-        
-      clazz = (*env)->FindClass (env, "org/apache/harmony/luni/util/Version");
-      if (!clazz) return 3;
-        
-      mID = (*env)->GetStaticMethodID (env, clazz, "version",
-                         "(Ljava/lang/String;)V");
-      if (!mID) return 3;
-        
-      (*env)->CallStaticVoidMethod(env, clazz, mID, jStrObject);
-        
-      return 0;
-  }
-
   if (mainClass)
     {
       if (isStandaloneJar)
@@ -968,8 +952,7 @@
    {
        if ( (strcmp (argv[i], "-jar") != 0) 
            && (strncmp (argv[i], "-vmdir:", 7) != 0)
-           && (strncmp (argv[i], "-vm:", 4) != 0) 
-           && (strncmp (argv[i], "-version", 8) != 0))
+           && (strncmp (argv[i], "-vm:", 4) != 0) )
        {
           /* special coding for -classpath and -cp */
           /* they get passed to the vm as -Djava.class.path */

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/unix/main_hlp.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/unix/main_hlp.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/unix/main_hlp.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/launcher/unix/main_hlp.c Thu Jun 11 16:05:16 2009
@@ -40,7 +40,7 @@
 #if defined(LINUX)
 #include <sys/sysinfo.h>
 #endif
-#if defined(FREEBSD)
+#if defined(FREEBSD) || defined(MACOSX)
 #include <sys/types.h>
 #include <sys/sysctl.h>
 #endif
@@ -62,7 +62,7 @@
 static IDATA searchSystemPath (char *filename, char **result);
 
 
-int 
+int
 main_get_executable_name (char *argv0, char **result)
 {
 
@@ -203,7 +203,7 @@
 	return pointer;
 }
 
-void 
+void
 main_mem_free_memory (void *memoryPointer)
 {
 	free (memoryPointer);
@@ -229,13 +229,13 @@
 }
 
 /**
- * @internal  Returns the current working directory.  
+ * @internal  Returns the current working directory.
  *
  * @return 0 on success, -1 on failure.
  *
- * @note The buffer to hold this string (including its terminating NUL) is allocated with 
- * main_mem_allocate_memory.  The caller should free this memory with 
- * main_mem_free_memory when it is no longer needed. 
+ * @note The buffer to hold this string (including its terminating NUL) is allocated with
+ * main_mem_allocate_memory.  The caller should free this memory with
+ * main_mem_free_memory when it is no longer needed.
  */
 static IDATA
 cwdname (char **result)
@@ -382,7 +382,7 @@
   return (UDATA) dlclose ((void *)descriptor);
 }
 
-/** 
+/**
  * Opens a shared library .
  *
  * @param[out] descriptor Pointer to memory which is filled in with shared-library handle on success.

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/cbigint.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/cbigint.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/cbigint.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/cbigint.c Thu Jun 11 16:05:16 2009
@@ -18,7 +18,7 @@
 #include <string.h>
 #include "cbigint.h"
 
-#if defined(LINUX) || defined(FREEBSD) || defined(ZOS)
+#if defined(LINUX) || defined(FREEBSD) || defined(ZOS) || defined(MACOSX)
 #define USE_LL
 #endif
 
@@ -665,7 +665,7 @@
      do {
      overflow = simpleAppendDecimalDigitHighPrecision(result, length, 0);
      if (overflow)
-     result[length++] = overflow; 
+     result[length++] = overflow;
      } while (--e);
    */
   return length;
@@ -686,7 +686,7 @@
      do {
      overflow = simpleAppendDecimalDigitHighPrecision(result, length, 0);
      if (overflow)
-     result[length++] = overflow; 
+     result[length++] = overflow;
      } while (--e);
    */
   /* Replace the current implementaion which performs a

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/dblparse.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/dblparse.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/dblparse.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/dblparse.c Thu Jun 11 16:05:16 2009
@@ -22,7 +22,7 @@
 #include "harmonyglob.h"
 #include "exceptions.h"
 
-#if defined(LINUX) || defined(FREEBSD) || defined(ZOS)
+#if defined(LINUX) || defined(FREEBSD) || defined(ZOS) || defined(MACOSX)
 #define USE_LL
 #endif
 
@@ -673,7 +673,7 @@
  *           1.234123412431233E107
  *           1.2341234124312331E107
  *           1.2341234124312331E107
- * 
+ *
  */
 JNIEXPORT void JNICALL
 Java_org_apache_harmony_luni_util_NumberConverter_bigIntDigitGeneratorInstImpl (JNIEnv *

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/fltparse.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/fltparse.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/fltparse.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/fltparse.c Thu Jun 11 16:05:16 2009
@@ -22,7 +22,7 @@
 #include "harmonyglob.h"
 #include "exceptions.h"
 
-#if defined(LINUX) || defined(FREEBSD) || defined(ZOS)
+#if defined(LINUX) || defined(FREEBSD) || defined(MACOSX) || defined(ZOS)
 #define USE_LL
 #endif
 

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/luni_copyright.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/luni_copyright.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/luni_copyright.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/shared/luni_copyright.c Thu Jun 11 16:05:16 2009
@@ -18,4 +18,4 @@
 /* A copyright string included in each DLL and executable */
 
 const char hyCopyright[] =
-  "(c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as applicable.";
+  "(c) Copyright 1991, 2009 The Apache Software Foundation or its licensors, as applicable.";

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSFileSystemLinux32.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSFileSystemLinux32.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSFileSystemLinux32.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSFileSystemLinux32.c Thu Jun 11 16:05:16 2009
@@ -23,7 +23,7 @@
 #include <fcntl.h>
 #include <unistd.h>
 #include <errno.h>
-#if defined(FREEBSD) || defined(AIX) || defined(ZOS)
+#if defined(FREEBSD) || defined(AIX) || defined(ZOS) || defined(MACOSX)
 #include <sys/types.h>
 #include <sys/socket.h>
 #else
@@ -42,7 +42,7 @@
 #define FD_BIAS 0
 #endif /* ZOS */
 
-typedef int OSSOCKET;   
+typedef int OSSOCKET;
 typedef struct hysocket_struct
 {
   OSSOCKET sock;
@@ -164,11 +164,11 @@
   jboolean bufsCopied = JNI_FALSE;
   jboolean offsetsCopied = JNI_FALSE;
   jboolean lengthsCopied = JNI_FALSE;
-  jlong *bufs; 
+  jlong *bufs;
   jint *offsets;
   jint *lengths;
   int i = 0;
-  long totalRead = 0;  
+  long totalRead = 0;
   struct iovec *vectors = (struct iovec *)hymem_allocate_memory(size * sizeof(struct iovec));
   if(vectors == NULL){
     return -1;
@@ -206,11 +206,11 @@
   jboolean bufsCopied = JNI_FALSE;
   jboolean offsetsCopied = JNI_FALSE;
   jboolean lengthsCopied = JNI_FALSE;
-  jlong *bufs; 
+  jlong *bufs;
   jint *offsets;
   jint *lengths;
   int i = 0;
-  long totalWritten = 0;  
+  long totalWritten = 0;
   struct iovec *vectors = (struct iovec *)hymem_allocate_memory(size * sizeof(struct iovec));
   if(vectors == NULL){
     return -1;
@@ -269,10 +269,12 @@
    The conversion here is to guarantee no value lost when converting offset to off_t
    */
   off_t off = offset;
-#if !defined(FREEBSD)
-  return sendfile(socket,(int)fd,(off_t *)&off,(size_t)count);	
+#if defined(FREEBSD)
+  return sendfile(fd-FD_BIAS, socket, off, (size_t)count, NULL, NULL, 0);
+#elif defined(MACOSX)
+  return sendfile((int)fd-FD_BIAS, (int)socket, off, (off_t *)&count, NULL, 0);
 #else
-  return sendfile(fd, socket, off, (size_t)count, NULL, NULL, 0);
+  return sendfile(socket,(int)fd-FD_BIAS,(off_t *)&off,(size_t)count);
 #endif
 #endif
 }

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSMemoryLinux32.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSMemoryLinux32.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSMemoryLinux32.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/OSMemoryLinux32.c Thu Jun 11 16:05:16 2009
@@ -30,6 +30,12 @@
 #include "OSMemory.h"
 #include "IMemorySystem.h"
 
+#ifdef ZOS
+#define FD_BIAS 1000
+#else
+#define FD_BIAS 0
+#endif /* ZOS */
+
 /* z/OS mman.h does not define MAP_FAILED - it should always be ((void*)-1) */
 #ifndef MAP_FAILED
 #define MAP_FAILED      ((void *) -1)
@@ -95,7 +101,7 @@
   	  jboolean result = 0;
   	  IDATA m_addr = (IDATA)addr;
 	  int page_size = getPageSize();
-#if defined(FREEBSD)
+#if defined(FREEBSD) || defined(MACOSX)
 #define HY_VEC_T char
 #else
 #define HY_VEC_T unsigned char
@@ -137,7 +143,7 @@
 JNIEXPORT void JNICALL Java_org_apache_harmony_luni_platform_OSMemory_unmapImpl
   (JNIEnv * env, jobject thiz, jlong addr, jlong size)
 {
-    munmap((void *)((IDATA)addr), (size_t)size); 
+    munmap((void *)((IDATA)addr), (size_t)size);
 }
 
 /*
@@ -151,7 +157,7 @@
   //PORT_ACCESS_FROM_ENV (env);
   void *mapAddress = NULL;
   int prot, flags;
-		  
+
   // Convert from Java mapping mode to port library mapping mode.
   switch (mmode)
     {
@@ -171,7 +177,7 @@
         return -1;
     }
 
-  mapAddress = mmap(0, (size_t)(size&0x7fffffff), prot, flags,fd,(off_t)(alignment&0x7fffffff));
+  mapAddress = mmap(0, (size_t)(size&0x7fffffff), prot, flags, fd-FD_BIAS, (off_t)(alignment&0x7fffffff));
   if (mapAddress == MAP_FAILED)
     {
       return -1;

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/helpers.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/helpers.c?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/helpers.c (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/unix/helpers.c Thu Jun 11 16:05:16 2009
@@ -314,7 +314,7 @@
     // tmStruct->tm_isdst is set to 1 if DST is in effect
     strcpy(tzInfo, "GMT");
     tzInfo[3] = timezone > 0 ? '-' : '+';
-#if defined (FREEBSD)
+#if defined (FREEBSD) || defined(MACOSX)
     h = labs(tmStruct->tm_gmtoff) / 3600;
 #else /* !FREEBSD */
     h = labs(timezone) / 3600;
@@ -326,7 +326,7 @@
             h++;
         }
     }
-#if defined (FREEBSD)
+#if defined (FREEBSD) || defined(MACOSX)
     m = (labs(tmStruct->tm_isdst) % 3600) / 60;
 #else /* !FREEBSD */
     m = (labs(timezone) % 3600) / 60;

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/native/luni/windows/makefile Thu Jun 11 16:05:16 2009
@@ -52,6 +52,6 @@
   $(LIBPATH)hyfdlibm$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13200000
-COMMENT=/comment:"LUNI component native code. (c) Copyright 1991, 2007 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"LUNI component native code. (c) Copyright 1991, 2009 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/io/FileTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/io/FileTest.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/io/FileTest.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/io/FileTest.java Thu Jun 11 16:05:16 2009
@@ -60,12 +60,14 @@
         // Delete all old temporary files
         File tempDir = new File(System.getProperty("java.io.tmpdir"));
         File[] files = tempDir.listFiles();
-        for (File file : files) {
-            if (file.getName().startsWith("harmony-test")) {
-                if (file.isDirectory()) {
-                    deleteTempFolder(file);
+        if (files != null) {
+            for (File file : files) {
+                if (file.getName().startsWith("harmony-test")) {
+                    if (file.isDirectory()) {
+                        deleteTempFolder(file);
+                    }
+                    file.delete();
                 }
-                file.delete();
             }
         }
     }

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/lang/StringBuilderTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/lang/StringBuilderTest.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/lang/StringBuilderTest.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/lang/StringBuilderTest.java Thu Jun 11 16:05:16 2009
@@ -572,6 +572,15 @@
 		} catch (StringIndexOutOfBoundsException e) {
 			// Expected
 		}
+
+                // HARMONY 6212
+                sb = new StringBuilder();
+                sb.append("abcde");
+                String str = sb.toString();
+                sb.delete(0, sb.length());
+                sb.append("YY");
+                assertEquals("abcde", str);
+                assertEquals("YY", sb.toString());
 	}
 
 	/**

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/URLClassLoaderTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/URLClassLoaderTest.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/URLClassLoaderTest.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/URLClassLoaderTest.java Thu Jun 11 16:05:16 2009
@@ -18,6 +18,7 @@
 package org.apache.harmony.luni.tests.java.net;
 
 import java.io.File;
+import java.io.FileOutputStream;
 import java.io.IOException;
 import java.io.InputStream;
 import java.net.MalformedURLException;
@@ -29,6 +30,10 @@
 import java.util.NoSuchElementException;
 import java.util.StringTokenizer;
 import java.util.Vector;
+import java.util.jar.Attributes;
+import java.util.jar.JarFile;
+import java.util.jar.JarOutputStream;
+import java.util.jar.Manifest;
 
 import junit.framework.TestCase;
 import tests.support.Support_Configuration;
@@ -477,4 +482,35 @@
         in = this.getClass().getResourceAsStream("test%25.properties");
         assertNull(in);
     }
+    
+    /**
+     * Regression test for HARMONY-6074
+     */
+    public void test_findClassLjava_lang_String_Jar_Class_Path() throws Exception{
+        File resources = Support_Resources.createTempFolder();
+        String resPath = resources.toString();
+        if (resPath.charAt(0) == '/' || resPath.charAt(0) == '\\') {
+            resPath = resPath.substring(1);
+        }
+        
+        Support_Resources.copyFile(resources, "JarIndex", "hyts_11.jar");
+        Support_Resources.copyFile(resources, "JarIndex", "hyts_13.jar");
+
+        JarFile jarFile = new JarFile(resources.getAbsolutePath() + "/JarIndex/hyts_11.jar");
+        Manifest mf = jarFile.getManifest(); 
+        Attributes attrs = mf.getMainAttributes();
+        attrs.putValue("Class-Path", "file:/" + resPath + "/JarIndex/hyts_13.jar");
+        
+        File mainJar = new File(resources.getAbsolutePath() + "/JarIndex/main.jar");
+        JarOutputStream jos = new JarOutputStream(new FileOutputStream(mainJar), mf);
+        jos.flush();
+        jos.close();
+        assertTrue(mainJar.exists());
+
+        URL[] urls = new URL[1];
+        urls[0] = new URL("file:/" + resPath + "/JarIndex/main.jar");
+        ucl = URLClassLoader.newInstance(urls, null);
+        assertNotNull(Class.forName("Main2", true, ucl));
+    }
+
 }

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/HashtableTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/HashtableTest.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/HashtableTest.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/HashtableTest.java Thu Jun 11 16:05:16 2009
@@ -106,6 +106,12 @@
 				ht.get("Ooga") == secondVal);
 	}
 
+    public void test_HashTable_Constructor() {
+        Hashtable hashTable = new Hashtable();
+        hashTable.put(hashTable, hashTable.keySet());
+        new Hashtable(hashTable);
+    }
+
 	/**
 	 * @tests java.util.Hashtable#clear()
 	 */
@@ -579,6 +585,28 @@
 		assertTrue("Remove failed", !h.containsKey("FKey 0") || k == null);
 	}
 
+    public void test_HashTable_remove_scenario1() {
+        Hashtable hashTable = new Hashtable();
+        Set keySet = hashTable.keySet();
+        hashTable.put(hashTable, keySet);
+        hashTable.remove(hashTable);
+    }
+
+    public void test_HashTable_remove_scenario2() {
+        Hashtable hashTable = new Hashtable();
+        Set keySet = hashTable.keySet();
+        hashTable.put(hashTable, hashTable);
+        hashTable.remove(hashTable);
+    }
+
+    public void test_HashTable_remove_scenario3() {
+        Hashtable hashTable = new Hashtable();
+        Hashtable keyHashTable = new Hashtable();
+        keyHashTable.put(hashTable, keyHashTable);
+        hashTable.put(keyHashTable, hashTable);
+        hashTable.remove(keyHashTable);
+    }
+
 	/**
 	 * @tests java.util.Hashtable#size()
 	 */

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMap2Test.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMap2Test.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMap2Test.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMap2Test.java Thu Jun 11 16:05:16 2009
@@ -115,6 +115,15 @@
         assertEquals("Size should be 0", 0, hm2.size());
 	}
 
+    public void test_IdentityHashMap_Constructor_BigSize() {
+        try {
+            new IdentityHashMap(Integer.MAX_VALUE);
+            fail("should throw OutOfMemoryError");
+        } catch (OutOfMemoryError e) {
+            // Expected
+        }
+    }
+
 	/**
 	 * @tests java.util.IdentityHashMap#clear()
 	 */

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMapTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMapTest.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMapTest.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/org/apache/harmony/luni/tests/java/util/IdentityHashMapTest.java Thu Jun 11 16:05:16 2009
@@ -357,6 +357,59 @@
 				.equals(newset));
 	}
 
+    public void test_clone_scenario1() {
+        IdentityHashMap hashMap = new IdentityHashMap();
+        assertEquals(0, hashMap.hashCode());
+        Object cloneHashMap = hashMap.clone();
+        ((IdentityHashMap) cloneHashMap).put("key", "value");
+        assertEquals(0, hashMap.hashCode());
+        assertTrue(0 != cloneHashMap.hashCode());
+    }
+
+    public void test_clone_scenario2() {
+        IdentityHashMap hashMap = new IdentityHashMap();
+        assertEquals(0, hashMap.hashCode());
+        Object cloneHashMap = hashMap.clone();
+        hashMap.put("key", "value");
+        assertEquals(1, hashMap.size());
+        assertEquals(0, ((IdentityHashMap) cloneHashMap).size());
+        assertEquals("value", hashMap.get("key"));
+        assertNull(((IdentityHashMap) cloneHashMap).get("key"));
+        assertTrue(0 != hashMap.hashCode());
+        assertEquals(0, cloneHashMap.hashCode());
+    }
+
+    public void test_clone_scenario3() {
+        IdentityHashMap hashMap = new IdentityHashMap();
+        assertEquals(0, hashMap.hashCode());
+        hashMap.put("key", "value");
+        Object cloneHashMap = hashMap.clone();
+        assertEquals(1, hashMap.size());
+        assertEquals(1, ((IdentityHashMap) cloneHashMap).size());
+        assertEquals("value", hashMap.get("key"));
+        assertEquals("value", ((IdentityHashMap) cloneHashMap).get("key"));
+        assertEquals(hashMap.hashCode(), cloneHashMap.hashCode());
+    }
+
+    public void test_clone_scenario4() {
+        IdentityHashMap hashMap = new IdentityHashMap();
+        Object cloneHashMap = hashMap.clone();
+        assertNull(((IdentityHashMap) cloneHashMap).get((Object) null));
+        hashMap.put((Object) null, cloneHashMap);
+        assertNull(((IdentityHashMap) cloneHashMap).get((Object) null));
+        assertEquals(cloneHashMap, hashMap.get((Object) null));
+    }
+
+    public void test_clone_scenario5() throws Exception {
+        IdentityHashMap hashMap = new IdentityHashMap();
+        Object cloneHashMap = hashMap.clone();
+        assertNull(hashMap.remove((Object) null));
+        ((IdentityHashMap) cloneHashMap).put((Object) null, cloneHashMap);
+        assertNull(hashMap.remove((Object) null));
+        assertEquals(cloneHashMap, ((IdentityHashMap) cloneHashMap)
+                .get((Object) null));
+    }
+
     // comparator for IdentityHashMap objects
     private static final SerializableAssert COMPARATOR = new SerializableAssert() {
         public void assertDeserialized(Serializable initial,

Modified: harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/shared/MemMacros.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/shared/MemMacros.h?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/shared/MemMacros.h (original)
+++ harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/shared/MemMacros.h Thu Jun 11 16:05:16 2009
@@ -15,7 +15,7 @@
  *  limitations under the License.
  */
 
-#ifdef __linux__
+#if  defined(__linux__) || defined(MACOSX)
     #include <stdint.h>
 #else
     #include <stddef.h>
@@ -81,7 +81,7 @@
 #endif /* ifdef __i386__ */
 
 /* windows section */
-#else 
+#else
 
 #define get_unaligned(type, ptr) ( *((type *)((uintptr_t)(ptr))) )
 #define set_unaligned(type, ptr, val) ( (void) (*((type *)((uintptr_t)(ptr))) = val) )

Modified: harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/windows/makefile
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/windows/makefile?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/windows/makefile (original)
+++ harmony/enhanced/classlib/branches/java6/modules/misc/src/main/native/accessors/windows/makefile Thu Jun 11 16:05:16 2009
@@ -33,6 +33,6 @@
   $(LIBPATH)hypool$(HY_LINKLIB_SUFFIX) $(LIBPATH)hyfdlibm$(HY_LINKLIB_SUFFIX) $(LIBPATH)vmi$(HY_LINKLIB_SUFFIX)
 
 DLLBASE=0x13300000
-COMMENT=/comment:"Accessors native code. (c) Copyright 2006 The Apache Software Foundation or its licensors, as applicable."
+COMMENT=/comment:"Accessors native code. (c) Copyright 2006, 2008 The Apache Software Foundation or its licensors, as applicable."
 
 !include <$(HY_HDK)\build\make\rules.mak>

Modified: harmony/enhanced/classlib/branches/java6/modules/nio/src/main/java/common/java/nio/CharBuffer.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/nio/src/main/java/common/java/nio/CharBuffer.java?rev=783825&r1=783824&r2=783825&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/nio/src/main/java/common/java/nio/CharBuffer.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/nio/src/main/java/common/java/nio/CharBuffer.java Thu Jun 11 16:05:16 2009
@@ -782,16 +782,22 @@
      *         read from this buffer.
      */
     public int read(CharBuffer target) throws IOException {
+        int remaining = remaining();
         if (target == this) {
+            if (remaining == 0) {
+                return -1;
+            }
             throw new IllegalArgumentException();
         }
-        if (remaining() == 0) {
-            return target.remaining() == 0 ? 0 : -1;
+        if (remaining == 0) {
+            return limit > 0 && target.remaining() == 0 ? 0 : -1;
         }
-        int result = Math.min(target.remaining(), remaining());
-        char[] chars = new char[result];
-        get(chars);
-        target.put(chars);
-        return result;
+        remaining = Math.min(target.remaining(), remaining);
+        if (remaining > 0) {
+            char[] chars = new char[remaining];
+            get(chars);
+            target.put(chars);
+        }
+        return remaining;
     }
 }



Mime
View raw message