aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/protocol/UlbotechProtocolDecoder.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/protocol/UlbotechProtocolDecoder.java')
-rw-r--r--src/org/traccar/protocol/UlbotechProtocolDecoder.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/org/traccar/protocol/UlbotechProtocolDecoder.java b/src/org/traccar/protocol/UlbotechProtocolDecoder.java
index 712444d95..3dc5b36cb 100644
--- a/src/org/traccar/protocol/UlbotechProtocolDecoder.java
+++ b/src/org/traccar/protocol/UlbotechProtocolDecoder.java
@@ -101,7 +101,10 @@ public class UlbotechProtocolDecoder extends BaseProtocolDecoder {
ChannelBuffer buf = (ChannelBuffer) msg;
- buf.readByte(); // header
+ if (buf.readUnsignedByte() != 0xF8) {
+ return null;
+ }
+
buf.readUnsignedByte(); // version
buf.readUnsignedByte(); // type
@@ -218,6 +221,7 @@ public class UlbotechProtocolDecoder extends BaseProtocolDecoder {
if (hasLocation) {
return position;
}
+
return null;
}