From 04dd07ab82e8af604fe66df7bc92e59d45c0c916 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Sat, 27 Feb 2016 10:03:45 +1300 Subject: Handle empty values in parser --- src/org/traccar/helper/Parser.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/org/traccar/helper') diff --git a/src/org/traccar/helper/Parser.java b/src/org/traccar/helper/Parser.java index 73713c51c..dcea1c8f7 100644 --- a/src/org/traccar/helper/Parser.java +++ b/src/org/traccar/helper/Parser.java @@ -46,7 +46,8 @@ public class Parser { } public boolean hasNext(int number) { - if (matcher.group(position) != null) { + String value = matcher.group(position); + if (value != null && !value.isEmpty()) { return true; } else { position += number; -- cgit v1.2.3