felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clem...@apache.org
Subject svn commit: r701348 - /felix/trunk/ipojo/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java
Date Fri, 03 Oct 2008 10:49:50 GMT
Author: clement
Date: Fri Oct  3 03:49:49 2008
New Revision: 701348

URL: http://svn.apache.org/viewvc?rev=701348&view=rev
Log:
Fix the FELIX-751 issue.
The setter method for array field has a bad access. Private was used instead of 0. This access
has an impact on the instruction to use to call the method (INVOKESPECIAL to INVOKEVIRTUAL).

Modified:
    felix/trunk/ipojo/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java

Modified: felix/trunk/ipojo/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java?rev=701348&r1=701347&r2=701348&view=diff
==============================================================================
--- felix/trunk/ipojo/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java
(original)
+++ felix/trunk/ipojo/manipulator/src/main/java/org/apache/felix/ipojo/manipulation/MethodCreator.java
Fri Oct  3 03:49:49 2008
@@ -188,6 +188,7 @@
 
         if ((access & ACC_STATIC) == ACC_STATIC) { return super.visitMethod(access, name,
desc, signature, exceptions); }
 
+        
         generateMethodHeader(access, name, desc, signature, exceptions);
         
         
@@ -299,6 +300,7 @@
         GeneratorAdapter mv = new GeneratorAdapter(cv.visitMethod(access, name, desc, signature,
exceptions), access, name, desc); 
         
         mv.visitCode();
+        
         Type returnType = Type.getReturnType(desc);
 
         // Compute result and exception stack location
@@ -581,7 +583,7 @@
      * @param type : contained type (inside the array)
      */
     private void createArraySetter(String name, String desc, Type type) {
-        MethodVisitor mv = cv.visitMethod(ACC_PRIVATE, "__set" + name, desc, null, null);
+        MethodVisitor mv = cv.visitMethod(0, "__set" + name, desc, null, null);
         mv.visitCode();
 
         String internalType = desc.substring(1);



Mime
View raw message