From d4dbf85d9536bfec85252a58fc552e2bad42ff17 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Sun, 4 Oct 2015 13:20:46 +1300 Subject: Remove trailing whitespaces from code --- src/org/traccar/protocol/CastelProtocolDecoder.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/org/traccar/protocol/CastelProtocolDecoder.java') diff --git a/src/org/traccar/protocol/CastelProtocolDecoder.java b/src/org/traccar/protocol/CastelProtocolDecoder.java index 95862cc9a..bd20def8b 100644 --- a/src/org/traccar/protocol/CastelProtocolDecoder.java +++ b/src/org/traccar/protocol/CastelProtocolDecoder.java @@ -86,9 +86,9 @@ public class CastelProtocolDecoder extends BaseProtocolDecoder { int version = buf.readUnsignedByte(); ChannelBuffer id = buf.readBytes(20); int type = ChannelBuffers.swapShort(buf.readShort()); - + if (type == MSG_HEARTBEAT) { - + if (channel != null) { ChannelBuffer response = ChannelBuffers.directBuffer(ByteOrder.LITTLE_ENDIAN, 31); response.writeByte(0x40); response.writeByte(0x40); @@ -107,7 +107,7 @@ public class CastelProtocolDecoder extends BaseProtocolDecoder { type == MSG_GPS || type == MSG_ALARM || type == MSG_CURRENT_LOCATION) { - + if (!identify(id.toString(Charset.defaultCharset()).trim(), channel, remoteAddress)) { return null; @@ -128,7 +128,7 @@ public class CastelProtocolDecoder extends BaseProtocolDecoder { response.writeByte(0x0D); response.writeByte(0x0A); channel.write(response, remoteAddress); } - + } if (type == MSG_GPS) { @@ -138,7 +138,7 @@ public class CastelProtocolDecoder extends BaseProtocolDecoder { } else if (type == MSG_CURRENT_LOCATION) { buf.readUnsignedShort(); } - + buf.readUnsignedInt(); // ACC ON time buf.readUnsignedInt(); // UTC time long odometer = buf.readUnsignedInt(); @@ -147,7 +147,7 @@ public class CastelProtocolDecoder extends BaseProtocolDecoder { buf.readUnsignedShort(); // current fuel consumption long status = buf.readUnsignedInt(); buf.skipBytes(8); - + int count = buf.readUnsignedByte(); List positions = new LinkedList<>(); @@ -184,7 +184,7 @@ public class CastelProtocolDecoder extends BaseProtocolDecoder { return position; } - + return null; } -- cgit v1.2.3