Close #410 - forge crashes

This commit is contained in:
md_5 2013-06-02 10:30:44 +10:00
parent d1dd7379b1
commit 18f5ed3102

View File

@ -110,6 +110,11 @@ public class UpstreamBridge extends PacketHandler
{
throw new CancelSendSignal();
}
// Hack around Forge race conditions
if ( ( pluginMessage.getData()[0] & 0xFF ) == 1 && pluginMessage.getTag().equals( "FML" ) )
{
throw new CancelSendSignal();
}
PluginMessageEvent event = new PluginMessageEvent( con, con.getServer(), pluginMessage.getTag(), pluginMessage.getData().clone() );
if ( bungee.getPluginManager().callEvent( event ).isCancelled() )