aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/protocol/IntellitracFrameDecoder.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/protocol/IntellitracFrameDecoder.java')
-rw-r--r--src/org/traccar/protocol/IntellitracFrameDecoder.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/org/traccar/protocol/IntellitracFrameDecoder.java b/src/org/traccar/protocol/IntellitracFrameDecoder.java
index 7c981a81b..4e6241a40 100644
--- a/src/org/traccar/protocol/IntellitracFrameDecoder.java
+++ b/src/org/traccar/protocol/IntellitracFrameDecoder.java
@@ -16,19 +16,16 @@
package org.traccar.protocol;
import org.jboss.netty.buffer.ChannelBuffer;
-import org.jboss.netty.buffer.ChannelBuffers;
import org.jboss.netty.channel.Channel;
import org.jboss.netty.channel.ChannelHandlerContext;
-import org.jboss.netty.handler.codec.frame.DelimiterBasedFrameDecoder;
+import org.jboss.netty.handler.codec.frame.LineBasedFrameDecoder;
-public class IntellitracFrameDecoder extends DelimiterBasedFrameDecoder {
+public class IntellitracFrameDecoder extends LineBasedFrameDecoder {
private static final int MESSAGE_MINIMUM_LENGTH = 0;
- private static final byte[] delimiter = {(byte) '\r', (byte) '\n'};
-
public IntellitracFrameDecoder(int maxFrameLength) {
- super(maxFrameLength, ChannelBuffers.wrappedBuffer(delimiter));
+ super(maxFrameLength);
}
// example of sync header: 0xFA 0xF8 0x1B 0x01 0x81 0x60 0x33 0x3C