Mercurial > hg > Database > Alice
diff src/main/java/alice/daemon/IncomingTcpConnection.java @ 555:2af387211a85 dispose
add zippedDataSize to ReceiveData
author | Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 19 Nov 2015 02:25:33 +0900 |
parents | 1dc473a637c6 |
children | 1a860019b2fe 72ef96ba4195 |
line wrap: on
line diff
--- a/src/main/java/alice/daemon/IncomingTcpConnection.java Tue Nov 17 00:53:02 2015 +0900 +++ b/src/main/java/alice/daemon/IncomingTcpConnection.java Thu Nov 19 02:25:33 2015 +0900 @@ -59,14 +59,16 @@ switch (type) { case UPDATE: case PUT: + int dataSize = unpacker.readInt(); if (msg.compressed) { - rData = new ReceiveData(packer.read(unpacker.getSerializedByteArray(unpacker.readInt()), byte[].class), true, msg.dataSize); + rData = new ReceiveData(packer.read(unpacker.getSerializedByteArray(dataSize), byte[].class), true, msg.dataSize); } else { - rData = new ReceiveData(unpacker.getSerializedByteArray(unpacker.readInt()), false, msg.dataSize); + rData = new ReceiveData(unpacker.getSerializedByteArray(dataSize), false, msg.dataSize); } if (msg.setTime) { rData.setTimes(msg.time, true, msg.depth); + rData.setZippedDataSize(dataSize); } cmd = new Command(type, null, null, rData, 0, 0, null, null, reverseKey);