|
|
@ -65,12 +65,6 @@ public class PacketDecoder { |
|
|
|
*/ |
|
|
|
packet = packet.replace("\\\\n", "\\n"); |
|
|
|
} |
|
|
|
|
|
|
|
int splitIndex = packet.indexOf(":"); |
|
|
|
String len = packet.substring(startPos, splitIndex); |
|
|
|
Integer length = Integer.valueOf(len); |
|
|
|
|
|
|
|
packet = packet.substring(splitIndex+1, splitIndex+length+1); |
|
|
|
packet = new String(packet.getBytes(CharsetUtil.ISO_8859_1), CharsetUtil.UTF_8); |
|
|
|
|
|
|
|
return Unpooled.wrappedBuffer(packet.getBytes(CharsetUtil.UTF_8)); |
|
|
|