]> sigrok.org Git - libsigrok.git/commitdiff
fx2lafw: Only run dslogic_stop_acquisition() on DSLogic.
authorUwe Hermann <redacted>
Sun, 17 Apr 2016 13:49:47 +0000 (15:49 +0200)
committerUwe Hermann <redacted>
Sun, 17 Apr 2016 13:49:47 +0000 (15:49 +0200)
src/hardware/fx2lafw/api.c

index 4af9dd8a484769166b2a91afe550c9273a9ee6b5..076c6a2e721e7da73ddce08fce17948868a4ef96 100644 (file)
@@ -821,9 +821,15 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi, void *cb_data)
 
 static int dev_acquisition_stop(struct sr_dev_inst *sdi, void *cb_data)
 {
+       struct dev_context *devc;
+
        (void)cb_data;
 
-       dslogic_stop_acquisition(sdi);
+       devc = sdi->priv;
+
+       if (devc->dslogic)
+               dslogic_stop_acquisition(sdi);
+
        fx2lafw_abort_acquisition(sdi->priv);
 
        return SR_OK;