tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fha...@apache.org
Subject svn commit: r730885 - /tomcat/trunk/modules/jdbc-pool/java/org/apache/tomcat/jdbc/pool/jmx/ConnectionPool.java
Date Sat, 03 Jan 2009 01:30:24 GMT
Author: fhanik
Date: Fri Jan  2 17:30:23 2009
New Revision: 730885

URL: http://svn.apache.org/viewvc?rev=730885&view=rev
Log:
Make system compile with JDK1.5

Modified:
    tomcat/trunk/modules/jdbc-pool/java/org/apache/tomcat/jdbc/pool/jmx/ConnectionPool.java

Modified: tomcat/trunk/modules/jdbc-pool/java/org/apache/tomcat/jdbc/pool/jmx/ConnectionPool.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/modules/jdbc-pool/java/org/apache/tomcat/jdbc/pool/jmx/ConnectionPool.java?rev=730885&r1=730884&r2=730885&view=diff
==============================================================================
--- tomcat/trunk/modules/jdbc-pool/java/org/apache/tomcat/jdbc/pool/jmx/ConnectionPool.java
(original)
+++ tomcat/trunk/modules/jdbc-pool/java/org/apache/tomcat/jdbc/pool/jmx/ConnectionPool.java
Fri Jan  2 17:30:23 2009
@@ -42,7 +42,7 @@
     }
 
     public ConnectionPool(org.apache.tomcat.jdbc.pool.ConnectionPool pool, boolean for16)
{
-        super(getDefaultNotificationInfo());
+        super();
         this.pool = pool;
     }
 
@@ -61,8 +61,16 @@
     
     @Override 
     public MBeanNotificationInfo[] getNotificationInfo() { 
-        return getDefaultNotificationInfo(); 
-    }
+	MBeanNotificationInfo[] pres = super.getNotificationInfo();
+	MBeanNotificationInfo[] loc = getDefaultNotificationInfo();
+	MBeanNotificationInfo[] aug = new MBeanNotificationInfo[
+						pres.length + loc.length
+							];
+ 	System.arraycopy(pres, 0, aug, 0, pres.length);
+	System.arraycopy(loc, 0, aug, pres.length+1, loc.length);	
+	
+        return aug; 
+    } 
     
     public static MBeanNotificationInfo[] getDefaultNotificationInfo() {
         String[] types = new String[] {NOTIFY_INIT, NOTIFY_CONNECT, NOTIFY_ABANDON}; 



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message