From: Bert Vermeulen Date: Thu, 1 Aug 2013 17:14:49 +0000 (+0200) Subject: ols: Workaround for mac os X stray events X-Git-Tag: libsigrok-0.2.1~19 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=faf720246ae6ec17e9ac47ee28c0320c1cfbd956;p=libsigrok.git ols: Workaround for mac os X stray events --- diff --git a/hardware/openbench-logic-sniffer/protocol.c b/hardware/openbench-logic-sniffer/protocol.c index 43f9f45c..ba782852 100644 --- a/hardware/openbench-logic-sniffer/protocol.c +++ b/hardware/openbench-logic-sniffer/protocol.c @@ -383,7 +383,7 @@ SR_PRIV int ols_receive_data(int fd, int revents, void *cb_data) num_channels++; } - if (revents == G_IO_IN) { + if (revents == G_IO_IN && devc->num_samples < devc->limit_samples) { if (serial_read(serial, &byte, 1) != 1) return FALSE;