mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-14 03:35:51 -07:00
SPIGOT-3723: Delegate PluginClassLoader back to parent
By: md_5 <git@md-5.net>
This commit is contained in:
@@ -116,10 +116,14 @@ final class PluginClassLoader extends URLClassLoader {
|
||||
CodeSource source = new CodeSource(url, signers);
|
||||
|
||||
result = defineClass(name, classBytes, 0, classBytes.length, source);
|
||||
}
|
||||
|
||||
if (result == null) {
|
||||
result = super.findClass(name);
|
||||
}
|
||||
|
||||
if (result != null) {
|
||||
loader.setClass(name, result);
|
||||
} else {
|
||||
throw new ClassNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user