# HG changeset patch # User kazz # Date 1328419903 -32400 # Node ID f9c82d9a4936f68c1d641d2f9948941abf392b52 # Parent 0f773308a863367a049007da3fc9b0abbc6357e7 move msgpack local val to static field; diff -r 0f773308a863 -r f9c82d9a4936 src/alice/daemon/IncomingTcpConnection.java --- a/src/alice/daemon/IncomingTcpConnection.java Sun Feb 05 06:42:23 2012 +0900 +++ b/src/alice/daemon/IncomingTcpConnection.java Sun Feb 05 14:31:43 2012 +0900 @@ -16,6 +16,7 @@ public class IncomingTcpConnection extends Thread { + private static MessagePack MSGPACK = new MessagePack(); public Connection connection; public DataSegmentManager manager; public String reverseKey; @@ -26,10 +27,9 @@ } public void run() { - MessagePack msgpack = new MessagePack(); Unpacker unpacker = null; try { - unpacker = msgpack.createUnpacker(connection.socket.getInputStream()); + unpacker = MSGPACK.createUnpacker(connection.socket.getInputStream()); } catch (IOException e2) { e2.printStackTrace(); }