]> sigrok.org Git - libsigrok.git/commitdiff
colead-slm: Mark serial write call as blocking.
authorMartin Ling <redacted>
Tue, 16 Sep 2014 00:52:14 +0000 (01:52 +0100)
committerUwe Hermann <redacted>
Wed, 24 Sep 2014 21:18:20 +0000 (23:18 +0200)
This driver opens the port without the SERIAL_NONBLOCK flag,
so this call was already blocking.

src/hardware/colead-slm/protocol.c

index ef58ab73c484ae8c02340060e946a9f1e9483df8..12a71546bb9f65de328255b8e489a2fed062dc33 100644 (file)
@@ -207,7 +207,7 @@ SR_PRIV int colead_slm_receive_data(int fd, int revents, void *cb_data)
                         * we don't want it. */
                        return TRUE;
                /* Got 0x10, "measurement ready". */
-               if (serial_write(serial, "\x20", 1) == -1)
+               if (serial_write_blocking(serial, "\x20", 1) == -1)
                        sr_err("unable to send command: %s", strerror(errno));
                else {
                        devc->state = COMMAND_SENT;