From 8ea5205fef8239f8beb0d5bd835b8fc117c9a082 Mon Sep 17 00:00:00 2001 From: md_5 Date: Fri, 15 Mar 2013 21:03:45 +1100 Subject: [PATCH] Reuse single packet instance to save overhead --- proxy/src/main/java/net/md_5/bungee/ServerConnector.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/proxy/src/main/java/net/md_5/bungee/ServerConnector.java b/proxy/src/main/java/net/md_5/bungee/ServerConnector.java index d35d4003..74132296 100644 --- a/proxy/src/main/java/net/md_5/bungee/ServerConnector.java +++ b/proxy/src/main/java/net/md_5/bungee/ServerConnector.java @@ -40,8 +40,7 @@ public class ServerConnector extends PacketHandler public void connected(Channel channel) throws Exception { this.ch = channel; - // TODO: Fix this crap - channel.write( new Packet2Handshake( user.handshake.procolVersion, user.handshake.username, user.handshake.host, user.handshake.port ) ); + channel.write( user.handshake ); channel.write( PacketCDClientStatus.CLIENT_LOGIN ); }