aboutsummaryrefslogtreecommitdiff
path: root/src/org
diff options
context:
space:
mode:
Diffstat (limited to 'src/org')
-rw-r--r--src/org/traccar/protocol/StarLinkProtocolDecoder.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/org/traccar/protocol/StarLinkProtocolDecoder.java b/src/org/traccar/protocol/StarLinkProtocolDecoder.java
index 0e9840766..8fbecc35e 100644
--- a/src/org/traccar/protocol/StarLinkProtocolDecoder.java
+++ b/src/org/traccar/protocol/StarLinkProtocolDecoder.java
@@ -100,6 +100,9 @@ public class StarLinkProtocolDecoder extends BaseProtocolDecoder {
int event = 0;
for (int i = 0; i < Math.min(data.length, dataTags.length); i++) {
+ if (data[i].isEmpty()) {
+ continue;
+ }
switch (dataTags[i]) {
case "#EDT#":
position.setDeviceTime(dateFormat.parse(data[i]));
@@ -180,6 +183,10 @@ public class StarLinkProtocolDecoder extends BaseProtocolDecoder {
}
}
+ if (position.getFixTime() == null) {
+ getLastLocation(position, null);
+ }
+
if (lac != null && cid != null) {
position.setNetwork(new Network(CellTower.fromLacCid(lac, cid)));
}