diff options
author | Anton Tananaev <anton@traccar.org> | 2024-05-21 06:41:44 -0700 |
---|---|---|
committer | Anton Tananaev <anton@traccar.org> | 2024-05-21 06:41:44 -0700 |
commit | c2c27617fa4392c3a25a6c4ad62bd24060f1c0c1 (patch) | |
tree | 537f577aa32a5e7c484b4afb0b5c02c1b35eaab3 /src/main/java/org/traccar/protocol/SnapperProtocol.java | |
parent | 445a2c5d0763bb42880ff1f9db93d755f6fdfa62 (diff) | |
download | trackermap-server-c2c27617fa4392c3a25a6c4ad62bd24060f1c0c1.tar.gz trackermap-server-c2c27617fa4392c3a25a6c4ad62bd24060f1c0c1.tar.bz2 trackermap-server-c2c27617fa4392c3a25a6c4ad62bd24060f1c0c1.zip |
Handle Snapper protocol ping
Diffstat (limited to 'src/main/java/org/traccar/protocol/SnapperProtocol.java')
-rw-r--r-- | src/main/java/org/traccar/protocol/SnapperProtocol.java | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/main/java/org/traccar/protocol/SnapperProtocol.java b/src/main/java/org/traccar/protocol/SnapperProtocol.java index 2e294eac6..25a11ed3a 100644 --- a/src/main/java/org/traccar/protocol/SnapperProtocol.java +++ b/src/main/java/org/traccar/protocol/SnapperProtocol.java @@ -15,15 +15,12 @@ */ package org.traccar.protocol; -import io.netty.handler.codec.LengthFieldBasedFrameDecoder; import jakarta.inject.Inject; import org.traccar.BaseProtocol; import org.traccar.PipelineBuilder; import org.traccar.TrackerServer; import org.traccar.config.Config; -import java.nio.ByteOrder; - public class SnapperProtocol extends BaseProtocol { @Inject @@ -31,7 +28,7 @@ public class SnapperProtocol extends BaseProtocol { addServer(new TrackerServer(config, getName(), false) { @Override protected void addProtocolHandlers(PipelineBuilder pipeline, Config config) { - pipeline.addLast(new LengthFieldBasedFrameDecoder(ByteOrder.LITTLE_ENDIAN, 1024, 12, 4, 9, 0, true)); + pipeline.addLast(new SnapperFrameDecoder()); pipeline.addLast(new SnapperProtocolDecoder(SnapperProtocol.this)); } }); |