Merge remote-tracking branch 'origin/pr/3125' into 1.10.x

This commit is contained in:
cpw 2016-07-28 18:25:45 -04:00
commit 5d9169db0f

View file

@ -36,8 +36,8 @@ public class FMLSecurityManager extends SecurityManager {
if (permName.startsWith("exitVM"))
{
Class<?>[] classContexts = getClassContext();
String callingClass = classContexts.length > 3 ? classContexts[4].getName() : "none";
String callingParent = classContexts.length > 4 ? classContexts[5].getName() : "none";
String callingClass = classContexts.length > 4 ? classContexts[4].getName() : "none";
String callingParent = classContexts.length > 5 ? classContexts[5].getName() : "none";
// FML is allowed to call system exit and the Minecraft applet (from the quit button)
if (!(callingClass.startsWith("net.minecraftforge.fml.")
|| "net.minecraft.server.dedicated.ServerHangWatchdog$1".equals(callingClass)