diff options
Diffstat (limited to 'src/org/traccar/protocol/Stl060FrameDecoder.java')
-rw-r--r-- | src/org/traccar/protocol/Stl060FrameDecoder.java | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/org/traccar/protocol/Stl060FrameDecoder.java b/src/org/traccar/protocol/Stl060FrameDecoder.java index 9eee11a02..0c271b243 100644 --- a/src/org/traccar/protocol/Stl060FrameDecoder.java +++ b/src/org/traccar/protocol/Stl060FrameDecoder.java @@ -20,14 +20,13 @@ 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.traccar.CharacterDelimiterFrameDecoder; import org.traccar.helper.ChannelBufferTools; -public class Stl060FrameDecoder extends DelimiterBasedFrameDecoder { - - private static final byte delimiter[] = { (byte) '#' }; +public class Stl060FrameDecoder extends CharacterDelimiterFrameDecoder { public Stl060FrameDecoder(int maxFrameLength) { - super(maxFrameLength, ChannelBuffers.wrappedBuffer(delimiter)); + super('#'); } @Override |