summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--gatchat/gathdlc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gatchat/gathdlc.c b/gatchat/gathdlc.c
index 9624bbd7..735a9d43 100644
--- a/gatchat/gathdlc.c
+++ b/gatchat/gathdlc.c
@@ -79,6 +79,9 @@ static void hdlc_record(int fd, gboolean in, guint8 *data, guint16 length)
if (fd < 0)
return;
+ if (len == 0)
+ return;
+
gettimeofday(&now, NULL);
ts = htonl(now.tv_sec & 0xffffffff);