diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/org/traccar/protocol/StarLinkProtocolDecoder.java | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/org/traccar/protocol/StarLinkProtocolDecoder.java b/src/org/traccar/protocol/StarLinkProtocolDecoder.java index 8d35ea5ba..97091257f 100644 --- a/src/org/traccar/protocol/StarLinkProtocolDecoder.java +++ b/src/org/traccar/protocol/StarLinkProtocolDecoder.java @@ -151,10 +151,14 @@ public class StarLinkProtocolDecoder extends BaseProtocolDecoder { position.set(Position.PREFIX_OUT + 4, Integer.parseInt(data[i])); break; case "#LAC#": - lac = Integer.parseInt(data[i]); + if (!data[i].isEmpty()) { + lac = Integer.parseInt(data[i]); + } break; case "#CID#": - cid = Integer.parseInt(data[i]); + if (!data[i].isEmpty()) { + cid = Integer.parseInt(data[i]); + } break; case "#VIN#": position.set(Position.KEY_POWER, Double.parseDouble(data[i])); |