ols: Workaround for mac os X stray events

This commit is contained in:
Bert Vermeulen 2013-08-01 19:14:49 +02:00
parent ce4d26ddf9
commit faf720246a
1 changed files with 1 additions and 1 deletions

View File

@ -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;