aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/org/traccar/protocol/Gt06ProtocolDecoder.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/org/traccar/protocol/Gt06ProtocolDecoder.java b/src/org/traccar/protocol/Gt06ProtocolDecoder.java
index 4d8161af9..0821de722 100644
--- a/src/org/traccar/protocol/Gt06ProtocolDecoder.java
+++ b/src/org/traccar/protocol/Gt06ProtocolDecoder.java
@@ -507,7 +507,7 @@ public class Gt06ProtocolDecoder extends BaseProtocolDecoder {
buf.readUnsignedInt(); // offset
buf.readBytes(photo, buf.readUnsignedShort());
- if (buf.writableBytes() > 0) {
+ if (photo.writableBytes() > 0) {
sendPhotoRequest(channel, pictureId);
} else {
Device device = Context.getDeviceManager().getDeviceById(deviceSession.getDeviceId());