From ed3950fbdccfbd118ed898066fc74c93e7542ec4 Mon Sep 17 00:00:00 2001 From: seym45 Date: Tue, 29 Aug 2023 16:13:47 +0400 Subject: Fix content size for encoding --- src/main/java/org/traccar/protocol/GatorProtocolEncoder.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/java/org/traccar/protocol') diff --git a/src/main/java/org/traccar/protocol/GatorProtocolEncoder.java b/src/main/java/org/traccar/protocol/GatorProtocolEncoder.java index 4a3e21d85..895c68af5 100644 --- a/src/main/java/org/traccar/protocol/GatorProtocolEncoder.java +++ b/src/main/java/org/traccar/protocol/GatorProtocolEncoder.java @@ -91,7 +91,7 @@ public class GatorProtocolEncoder extends BaseProtocolEncoder { String[] data = command.getString(Command.KEY_FREQUENCY).split(";"); content.writeShort(Integer.valueOf(data[0])); content.writeShort(Integer.valueOf(data[1])); - content.writeShort(Integer.valueOf(data[2])); + content.writeByte(Integer.valueOf(data[2])); return encodeContent(command.getDeviceId(), GatorProtocolDecoder.MSG_POSITION_PERIODIC, content); default: return null; -- cgit v1.2.3