Fix classloading issue preventing JRockit from running forge

This commit is contained in:
Christian 2012-10-19 09:30:31 -04:00
parent 2687a67e73
commit f3443d3e02

View file

@ -22,7 +22,7 @@ public class EventTransformer implements IClassTransformer
@Override
public byte[] transform(String name, byte[] bytes)
{
if (name.equals("net.minecraftforge.event.Event") || name.startsWith("net.minecraft.src.") || name.indexOf('.') == -1)
if (name.equals("net.minecraftforge.event.Event") || name.startsWith("net.minecraft.") || name.indexOf('.') == -1)
{
return bytes;
}
@ -61,7 +61,8 @@ public class EventTransformer implements IClassTransformer
boolean hasGetListenerList = false;
boolean hasDefaultCtr = false;
Type tList = Type.getType(ListenerList.class);
Class<?> listenerListClazz = Class.forName("net.minecraftforge.event.ListenerList", false, getClass().getClassLoader());
Type tList = Type.getType(listenerListClazz);
for (MethodNode method : (List<MethodNode>)classNode.methods)
{