]> sigrok.org Git - libsigrok.git/commitdiff
Fix the build when libusb is not available.
authorUwe Hermann <redacted>
Thu, 2 May 2013 15:37:55 +0000 (17:37 +0200)
committerUwe Hermann <redacted>
Fri, 3 May 2013 11:29:49 +0000 (13:29 +0200)
Thanks Simon Richter <redacted> for reporting.

std.c

diff --git a/std.c b/std.c
index fe0893461ef2fe990c4556d3e4092a2969dd493a..cfe031d993b5e7071e4066bd35c6c091091ff0a1 100644 (file)
--- a/std.c
+++ b/std.c
@@ -204,7 +204,11 @@ SR_PRIV int std_dev_clear(const struct sr_dev_driver *driver,
 
                if (sdi->conn) {
                        if (sdi->inst_type == SR_INST_USB)
+#if HAVE_LIBUSB_1_0
                                sr_usb_dev_inst_free(sdi->conn);
+#else
+                               ;
+#endif
                        else if (sdi->inst_type == SR_INST_SERIAL)
                                sr_serial_dev_inst_free(sdi->conn);
                }