From 30cf4d484307ad89ce538bae36c47c91eb430536 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Fri, 9 Oct 2015 22:33:56 +1300 Subject: Fix some check style issues --- src/org/traccar/protocol/ProgressProtocolDecoder.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/org/traccar/protocol/ProgressProtocolDecoder.java') diff --git a/src/org/traccar/protocol/ProgressProtocolDecoder.java b/src/org/traccar/protocol/ProgressProtocolDecoder.java index 08d2b12bc..bf7c649ce 100644 --- a/src/org/traccar/protocol/ProgressProtocolDecoder.java +++ b/src/org/traccar/protocol/ProgressProtocolDecoder.java @@ -70,8 +70,8 @@ public class ProgressProtocolDecoder extends BaseProtocolDecoder { int type = buf.readUnsignedShort(); buf.readUnsignedShort(); // length - // Authentication if (type == MSG_IDENT || type == MSG_IDENT_FULL) { + buf.readUnsignedInt(); // id int length = buf.readUnsignedShort(); buf.skipBytes(length); @@ -80,10 +80,9 @@ public class ProgressProtocolDecoder extends BaseProtocolDecoder { length = buf.readUnsignedShort(); String imei = buf.readBytes(length).toString(Charset.defaultCharset()); identify(imei, channel); - } - // Position - else if (hasDeviceId() && (type == MSG_POINT || type == MSG_ALARM || type == MSG_LOGMSG)) { + } else if (hasDeviceId() && (type == MSG_POINT || type == MSG_ALARM || type == MSG_LOGMSG)) { + List positions = new LinkedList<>(); int recordCount = 1; -- cgit v1.2.3