diff options
Diffstat (limited to 'src/org/traccar/protocol/Tk103FrameDecoder.java')
-rw-r--r-- | src/org/traccar/protocol/Tk103FrameDecoder.java | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/org/traccar/protocol/Tk103FrameDecoder.java b/src/org/traccar/protocol/Tk103FrameDecoder.java index e6f37981e..e8e0325da 100644 --- a/src/org/traccar/protocol/Tk103FrameDecoder.java +++ b/src/org/traccar/protocol/Tk103FrameDecoder.java @@ -38,7 +38,6 @@ public class Tk103FrameDecoder extends FrameDecoder { buf.clear(); return null; } - frameStartIndex++; int frameEndIndex, freeTextSymbolCounter; for (frameEndIndex = frameStartIndex, freeTextSymbolCounter = 0;; frameEndIndex++) { @@ -71,8 +70,7 @@ public class Tk103FrameDecoder extends FrameDecoder { } buf.readerIndex(frameStartIndex); - ChannelBuffer result = buf.readBytes(frameEndIndex - frameStartIndex); - buf.readerIndex(buf.readerIndex() + 1); + ChannelBuffer result = buf.readBytes(frameEndIndex + 1 - frameStartIndex); return result; |