commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From joe...@apache.org
Subject svn commit: r890594 - in /commons/proper/dbcp/trunk: pom.xml src/java/org/apache/commons/dbcp/DelegatingConnection.java src/test/org/apache/commons/dbcp/TestJOCLed.java
Date Tue, 15 Dec 2009 01:12:10 GMT
Author: joehni
Date: Tue Dec 15 01:12:09 2009
New Revision: 890594

URL: http://svn.apache.org/viewvc?rev=890594&view=rev
Log:
Use distinguishable hash codes, otherwise IBM JDK 1.6 has a problem with WeakReferences.

Modified:
    commons/proper/dbcp/trunk/pom.xml
    commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/DelegatingConnection.java
    commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJOCLed.java

Modified: commons/proper/dbcp/trunk/pom.xml
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/pom.xml?rev=890594&r1=890593&r2=890594&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/pom.xml (original)
+++ commons/proper/dbcp/trunk/pom.xml Tue Dec 15 01:12:09 2009
@@ -197,20 +197,6 @@
        <version>1.2-beta</version>
        <scope>test</scope>
     </dependency>
-
-    <!-- required under jdk 1.4 so jocl can have a sax parser -->
-    <dependency>
-      <groupId>xml-apis</groupId>
-      <artifactId>xml-apis</artifactId>
-      <version>2.0.2</version>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>xerces</groupId>
-      <artifactId>xerces</artifactId>
-      <version>2.4.0</version>
-      <scope>test</scope>
-    </dependency>
   </dependencies>
 
   <properties>

Modified: commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/DelegatingConnection.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/DelegatingConnection.java?rev=890594&r1=890593&r2=890594&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/DelegatingConnection.java (original)
+++ commons/proper/dbcp/trunk/src/java/org/apache/commons/dbcp/DelegatingConnection.java Tue
Dec 15 01:12:09 2009
@@ -17,29 +17,27 @@
 
 package org.apache.commons.dbcp;
 
+import java.sql.Array;
+import java.sql.Blob;
 import java.sql.CallableStatement;
+import java.sql.ClientInfoStatus;
+import java.sql.Clob;
 import java.sql.Connection;
 import java.sql.DatabaseMetaData;
+import java.sql.NClob;
 import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLClientInfoException;
 import java.sql.SQLException;
 import java.sql.SQLWarning;
+import java.sql.SQLXML;
 import java.sql.Statement;
+import java.sql.Struct;
+import java.util.Collections;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-import java.sql.ResultSet;
-/* JDBC_4_ANT_KEY_BEGIN */
-import java.sql.Array;
-import java.sql.Blob;
-import java.sql.ClientInfoStatus;
-import java.sql.Clob;
-import java.sql.NClob;
-import java.sql.SQLClientInfoException;
-import java.sql.SQLXML;
-import java.sql.Struct;
-import java.util.Collections;
 import java.util.Properties;
-/* JDBC_4_ANT_KEY_END */
 
 /**
  * A base delegating implementation of {@link Connection}.
@@ -195,7 +193,7 @@
         if (obj == null) {
             return 0;
         }
-        return obj.hashCode();
+        return obj.hashCode() >>> 1;
     }
 
 

Modified: commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJOCLed.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJOCLed.java?rev=890594&r1=890593&r2=890594&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJOCLed.java (original)
+++ commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestJOCLed.java Tue Dec 15
01:12:09 2009
@@ -30,9 +30,6 @@
 public class TestJOCLed extends TestConnectionPool {
     public TestJOCLed(String testName) {
         super(testName);
-        if(null == System.getProperty("org.xml.sax.driver")) {
-           System.setProperty("org.xml.sax.driver","org.apache.xerces.parsers.SAXParser");
-        }
     }
 
     public static Test suite() {



Mime
View raw message