]> sigrok.org Git - libsigrok.git/commitdiff
ols: Don't silently ignore error when setting up the device
authorv1ne <redacted>
Tue, 23 Feb 2021 21:36:33 +0000 (22:36 +0100)
committerSoeren Apel <redacted>
Fri, 10 Sep 2021 21:01:04 +0000 (23:01 +0200)
src/hardware/openbench-logic-sniffer/api.c

index 426d253a716385c36b3a539d0e0d30897cd0d2e2..788d4b8098c7a1ca4c5dc8276d8adb93183c6849 100644 (file)
@@ -419,10 +419,8 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi)
        /* If the device stops sending for longer than it takes to send a byte,
         * that means it's finished. But wait at least 100 ms to be safe.
         */
-       serial_source_add(sdi->session, serial, G_IO_IN, 100, ols_receive_data,
-                         (struct sr_dev_inst *)sdi);
-
-       return SR_OK;
+       return serial_source_add(sdi->session, serial, G_IO_IN, 100,
+                                ols_receive_data, (struct sr_dev_inst *)sdi);
 }
 
 static int dev_acquisition_stop(struct sr_dev_inst *sdi)