Null check

This commit is contained in:
vemacs 2014-04-26 11:24:57 -06:00 committed by Thinkofdeath
parent 71c86f9f90
commit e4e01ccb55

View File

@ -345,9 +345,12 @@ public class DownstreamBridge extends PacketHandler
if ( subChannel.equals( "ServerIP" ) )
{
ServerInfo info = bungee.getServerInfo( in.readUTF() );
out.writeUTF( "ServerIP" );
out.writeUTF( info.getAddress().getAddress().getHostAddress() );
out.writeShort( info.getAddress().getPort() );
if ( info != null )
{
out.writeUTF( "ServerIP" );
out.writeUTF( info.getAddress().getAddress().getHostAddress() );
out.writeShort( info.getAddress().getPort() );
}
}
// Check we haven't set out to null, and we have written data, if so reply back back along the BungeeCord channel