openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p..@apache.org
Subject svn commit: r656006 - /openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCClassFileTransformer.java
Date Tue, 13 May 2008 20:51:26 GMT
Author: pcl
Date: Tue May 13 13:51:25 2008
New Revision: 656006

URL: http://svn.apache.org/viewvc?rev=656006&view=rev
Log:
OPENJPA-600. Committing on behalf of Jason Zheng.

Modified:
    openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCClassFileTransformer.java

Modified: openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCClassFileTransformer.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCClassFileTransformer.java?rev=656006&r1=656005&r2=656006&view=diff
==============================================================================
--- openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCClassFileTransformer.java
(original)
+++ openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/enhance/PCClassFileTransformer.java
Tue May 13 13:51:25 2008
@@ -116,6 +116,18 @@
             return null;
 
         _transforming = true;
+
+        return transform0(className, redef, bytes);
+    }
+
+    /**
+     * We have to split the transform method into two methods to avoid
+     * ClassCircularityError when executing method using pure-JIT JVMs
+     * such as JRockit.
+     */
+    private byte[] transform0(String className, Class redef, byte[] bytes)
+        throws IllegalClassFormatException {
+
         try {
             Boolean enhance = needsEnhance(className, redef, bytes);
             if (enhance != null && _log.isTraceEnabled())



Mime
View raw message