Don't infinite loop.

This commit is contained in:
md_5 2013-02-01 20:32:34 +11:00
parent 5e3a3d438a
commit b923ea847b

View File

@ -20,6 +20,8 @@ public class PluginClassloader extends URLClassLoader
protected Class<?> findClass(String name) throws ClassNotFoundException protected Class<?> findClass(String name) throws ClassNotFoundException
{ {
for (PluginClassloader loader : allLoaders) for (PluginClassloader loader : allLoaders)
{
if (loader != this)
{ {
try try
{ {
@ -28,6 +30,7 @@ public class PluginClassloader extends URLClassLoader
{ {
} }
} }
}
throw new ClassNotFoundException(); throw new ClassNotFoundException();
} }
} }