return SR_ERR;
}
- sdi->status = SR_ST_ACTIVE;
-
return SR_OK;
}
usb = sdi->conn;
if (!usb->devhdl)
- return SR_OK;
+ return SR_ERR_BUG;
libusb_release_interface(usb->devhdl, USB_INTERFACE);
libusb_close(usb->devhdl);
usb->devhdl = NULL;
- sdi->status = SR_ST_INACTIVE;
return SR_OK;
}
(void)cg;
- if (sdi->status != SR_ST_ACTIVE)
- return SR_ERR_DEV_CLOSED;
-
switch (key) {
case SR_CONF_LIMIT_SAMPLES:
limit_samples = g_variant_get_uint64(data);
unsigned int i, j;
int ret;
- if (sdi->status != SR_ST_ACTIVE)
- return SR_ERR_DEV_CLOSED;
-
devc = sdi->priv;
drvc = di->context;