From: Martin Ling Date: Mon, 30 Dec 2013 03:00:41 +0000 (+0100) Subject: ols: Use serial source management wrappers. X-Git-Tag: libsigrok-0.3.0~359 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=264c99eda2084659492c18e0e7d0e662319053d9;p=libsigrok.git ols: Use serial source management wrappers. --- diff --git a/hardware/openbench-logic-sniffer/protocol.c b/hardware/openbench-logic-sniffer/protocol.c index 65e89e93..7b5ea6a5 100644 --- a/hardware/openbench-logic-sniffer/protocol.c +++ b/hardware/openbench-logic-sniffer/protocol.c @@ -381,8 +381,8 @@ SR_PRIV int ols_receive_data(int fd, int revents, void *cb_data) * longer than it takes to send a byte, that means it's * finished. We'll double that to 30ms to be sure... */ - sr_source_remove(fd); - sr_source_add(fd, G_IO_IN, 30, ols_receive_data, cb_data); + serial_source_remove(serial); + serial_source_add(serial, G_IO_IN, 30, ols_receive_data, cb_data); devc->raw_sample_buf = g_try_malloc(devc->limit_samples * 4); if (!devc->raw_sample_buf) { sr_err("Sample buffer malloc failed.");