aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/protocol/SatsolProtocolDecoder.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/protocol/SatsolProtocolDecoder.java')
-rw-r--r--src/org/traccar/protocol/SatsolProtocolDecoder.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/org/traccar/protocol/SatsolProtocolDecoder.java b/src/org/traccar/protocol/SatsolProtocolDecoder.java
index e9e8e4c56..b12a81a52 100644
--- a/src/org/traccar/protocol/SatsolProtocolDecoder.java
+++ b/src/org/traccar/protocol/SatsolProtocolDecoder.java
@@ -89,11 +89,11 @@ public class SatsolProtocolDecoder extends BaseProtocolDecoder {
if (channel != null) {
ByteBuf response = Unpooled.buffer();
- buf.writeShortLE(0);
- buf.writeShortLE(0x4CBF); // preamble
- buf.writeIntLE((int) id);
- buf.writeShortLE(0);
- buf.setShortLE(0, Checksum.crc16(
+ response.writeShortLE(0);
+ response.writeShortLE(0x4CBF); // preamble
+ response.writeIntLE((int) id);
+ response.writeShortLE(0);
+ response.setShortLE(0, Checksum.crc16(
Checksum.CRC16_CCITT_FALSE, response.nioBuffer(2, response.readableBytes() - 2)));
channel.writeAndFlush(new NetworkMessage(response, remoteAddress));
}