aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/chelper/serialqueue.c
diff options
context:
space:
mode:
Diffstat (limited to 'klippy/chelper/serialqueue.c')
-rw-r--r--klippy/chelper/serialqueue.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/klippy/chelper/serialqueue.c b/klippy/chelper/serialqueue.c
index f9cfd148..3684a721 100644
--- a/klippy/chelper/serialqueue.c
+++ b/klippy/chelper/serialqueue.c
@@ -573,7 +573,10 @@ input_event(struct serialqueue *sq, double eventtime)
int ret = read(sq->serial_fd, &sq->input_buf[sq->input_pos]
, sizeof(sq->input_buf) - sq->input_pos);
if (ret <= 0) {
- report_errno("read", ret);
+ if(ret < 0)
+ report_errno("read", ret);
+ else
+ errorf("Got EOF when reading from device");
pollreactor_do_exit(&sq->pr);
return;
}