From 9aeb9de070dd9af378c38b55ed48502c4fea53f5 Mon Sep 17 00:00:00 2001 From: Zlatin Balevsky Date: Fri, 27 Jul 2018 16:00:32 +0100 Subject: [PATCH] log length as well --- .../groovy/com/muwire/core/connection/PeerConnection.groovy | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/src/main/groovy/com/muwire/core/connection/PeerConnection.groovy b/core/src/main/groovy/com/muwire/core/connection/PeerConnection.groovy index 64d9b33a..c88b70b6 100644 --- a/core/src/main/groovy/com/muwire/core/connection/PeerConnection.groovy +++ b/core/src/main/groovy/com/muwire/core/connection/PeerConnection.groovy @@ -62,10 +62,10 @@ class PeerConnection extends Connection { protected void write(Object message) { byte[] payload if (message instanceof Map) { - log.fine "$name writing message type ${message.type}" payload = JsonOutput.toJson(message).bytes DataUtil.packHeader(payload.length, writeHeader) - writeHeader[0] &= 0x7F + log.fine "$name writing message type ${message.type} length $payload.length" + writeHeader[0] &= (byte)0x7F } else { // TODO: write binary }