fix dumb mistake leading to AIOOBEs in Class.getMethod

This commit is contained in:
Joel Dice 2014-01-03 13:58:37 -07:00
parent 56253e3123
commit d1bdf2f8ef

View File

@ -223,7 +223,7 @@ public final class Class <T> implements Type, AnnotatedElement {
for (VMClass c = vmClass; c != null; c = c.super_) {
int index = Classes.findMethod(c, name, parameterTypes);
if (index >= 0) {
return new Method(vmClass.methodTable[index]);
return new Method(c.methodTable[index]);
}
}
throw new NoSuchMethodException(name);