aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2016-02-07 07:45:44 +1000
committerAnton Tananaev <anton.tananaev@gmail.com>2016-02-07 07:45:44 +1000
commitf325f30ab8d9097eec01a39f5e7ac02c11d608c3 (patch)
tree78da8e3263612ff45e3b778fbeee0f7a1d04476f /src
parent18aaf44bcde8eb5243b069727fb4f056e94df938 (diff)
downloadtraccar-server-f325f30ab8d9097eec01a39f5e7ac02c11d608c3.tar.gz
traccar-server-f325f30ab8d9097eec01a39f5e7ac02c11d608c3.tar.bz2
traccar-server-f325f30ab8d9097eec01a39f5e7ac02c11d608c3.zip
Handle new line in Xexun messages
Diffstat (limited to 'src')
-rw-r--r--src/org/traccar/protocol/XexunProtocolDecoder.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/org/traccar/protocol/XexunProtocolDecoder.java b/src/org/traccar/protocol/XexunProtocolDecoder.java
index f9369b463..0929ee99b 100644
--- a/src/org/traccar/protocol/XexunProtocolDecoder.java
+++ b/src/org/traccar/protocol/XexunProtocolDecoder.java
@@ -44,8 +44,9 @@ public class XexunProtocolDecoder extends BaseProtocolDecoder {
.number("(d+.?d*)?,") // course
.number("(dd)(dd)(dd),") // date
.expression("[^*]*").text("*")
- .number("xx,") // checksum
- .expression("([FL]),") // signal
+ .number("xx") // checksum
+ .expression("\\r\\n").optional()
+ .expression(",([FL]),") // signal
.expression("([^,]*),").optional() // alarm
.any()
.number("imei:(d+),") // imei