aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/org/traccar/protocol/TmgFrameDecoder.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/org/traccar/protocol/TmgFrameDecoder.java b/src/org/traccar/protocol/TmgFrameDecoder.java
index 07b4162db..549c42466 100644
--- a/src/org/traccar/protocol/TmgFrameDecoder.java
+++ b/src/org/traccar/protocol/TmgFrameDecoder.java
@@ -47,13 +47,13 @@ public class TmgFrameDecoder extends FrameDecoder {
}
});
- if (beginIndex > 0) {
+ if (beginIndex >= 0) {
buf.readerIndex(beginIndex);
int endIndex = buf.indexOf(beginIndex, buf.writerIndex(), (byte) '\n');
- if (endIndex > 0) {
+ if (endIndex >= 0) {
ChannelBuffer frame = buf.readBytes(endIndex - beginIndex);
buf.readByte(); // delimiter
return frame;