Don't init class during reflection signature scan.

When processing Class.getDeclaredMethods() we create Method objects.
These have arrays of classes that indicate the method parameter types.
While generating the array we were initializing the classes we found,
which isn't necessary and led to some unpleasantness described in
external bug 3005.
diff --git a/tests/046-reflect/expected.txt b/tests/046-reflect/expected.txt
index eefa448..3be8d1c 100644
--- a/tests/046-reflect/expected.txt
+++ b/tests/046-reflect/expected.txt
@@ -92,3 +92,6 @@
 ReflectTest done!
 checkType invoking null
 checkType got expected exception
+got methods
+NoisyInitUser is initializing
+NoisyInit is initializing
diff --git a/tests/046-reflect/src/Main.java b/tests/046-reflect/src/Main.java
index 1ec63d8..99b1c4e 100644
--- a/tests/046-reflect/src/Main.java
+++ b/tests/046-reflect/src/Main.java
@@ -332,11 +332,23 @@
         }
     }
 
+    public static void checkInit() {
+        Class niuClass = NoisyInitUser.class;
+        Method[] methods;
+
+        methods = niuClass.getDeclaredMethods();
+        System.out.println("got methods");
+        /* neither NoisyInit nor NoisyInitUser should be initialized yet */
+        NoisyInitUser niu = new NoisyInitUser();
+        NoisyInit ni = new NoisyInit();
+    }
+
     public static void main(String[] args) {
         Main test = new Main();
         test.run();
 
         checkType();
+        checkInit();
     }
 }
 
@@ -407,3 +419,18 @@
     public static double staticDouble = 3.3;
 }
 
+class NoisyInit {
+    static {
+        System.out.println("NoisyInit is initializing");
+        //Throwable th = new Throwable();
+        //th.printStackTrace();
+    }
+}
+
+class NoisyInitUser {
+    static {
+        System.out.println("NoisyInitUser is initializing");
+    }
+    public void createNoisyInit(NoisyInit ni) {}
+}
+
diff --git a/vm/reflect/Reflect.c b/vm/reflect/Reflect.c
index b7de934..2e3c549 100644
--- a/vm/reflect/Reflect.c
+++ b/vm/reflect/Reflect.c
@@ -212,7 +212,7 @@
             ;
         savedChar = *++signature;
         *signature = '\0';
-        clazz = dvmFindClass(*pSignature, defClass->classLoader);
+        clazz = dvmFindClassNoInit(*pSignature, defClass->classLoader);
         *signature = savedChar;
     } else {
         clazz = dvmFindPrimitiveClass(*signature++);