You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by cl...@apache.org on 2012/02/21 08:58:24 UTC
svn commit: r1291639 -
/felix/trunk/ipojo/manipulator/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java
Author: clement
Date: Tue Feb 21 07:58:24 2012
New Revision: 1291639
URL: http://svn.apache.org/viewvc?rev=1291639&view=rev
Log:
Fixed FELIX-3359
downgrade the class version on 1.7.
Modified:
felix/trunk/ipojo/manipulator/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java
Modified: felix/trunk/ipojo/manipulator/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/manipulator/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java?rev=1291639&r1=1291638&r2=1291639&view=diff
==============================================================================
--- felix/trunk/ipojo/manipulator/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java (original)
+++ felix/trunk/ipojo/manipulator/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java Tue Feb 21 07:58:24 2012
@@ -547,8 +547,16 @@ public class MethodCreator extends Class
} else {
itfs = interfaces;
}
+
+ // If version = 1.7, use 1.6 if the ipojo.downgrade.classes system property is either
+ // not set of set to true.
+ int theVersion = version;
+ String downgrade = System.getProperty("ipojo.downgrade.classes");
+ if ((downgrade == null || "true".equals(downgrade)) && version == Opcodes.V1_7) {
+ theVersion = Opcodes.V1_6;
+ }
- cv.visit(version, access, name, signature, superName, itfs);
+ cv.visit(theVersion, access, name, signature, superName, itfs);
}
/**