From a4ad1371690e6d0840e717ec8e65a88fc3b60033 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Fri, 3 Aug 2018 04:28:13 +1200 Subject: Handle alternative GT06 message format --- src/org/traccar/protocol/Gt06ProtocolDecoder.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/org/traccar/protocol/Gt06ProtocolDecoder.java b/src/org/traccar/protocol/Gt06ProtocolDecoder.java index dfb0b5e07..e405bc195 100644 --- a/src/org/traccar/protocol/Gt06ProtocolDecoder.java +++ b/src/org/traccar/protocol/Gt06ProtocolDecoder.java @@ -251,8 +251,8 @@ public class Gt06ProtocolDecoder extends BaseProtocolDecoder { position.setNetwork(new Network(CellTower.from( BitUtil.to(mcc, 15), mnc, buf.readUnsignedShort(), buf.readUnsignedMedium()))); - if (length > 0) { - buf.skipBytes(length - (hasLength ? 9 : 8)); + if (length > 9) { + buf.skipBytes(length - 9); } return true; -- cgit v1.2.3