if (sdi->status == SR_ST_ACTIVE) {
sr_dbg("la8: Status ACTIVE, closing device.");
- /* TODO: Really ignore errors here, or return SR_ERR? */
(void) la8_close_usb_reset_sequencer(devc); /* Ignore errors. */
} else {
sr_spew("la8: Status not ACTIVE, nothing to do.");
hw_dev_acquisition_stop(sdi, sdi);
- // return FALSE; /* FIXME? */
return TRUE;
}
return SR_ERR;
} else if (bytes_written != 4) {
sr_err("la8: Acquisition failed to start.");
- return SR_ERR; /* TODO: Other error and return code? */
+ return SR_ERR;
}
sr_dbg("la8: Acquisition started successfully.");
static int hw_dev_acquisition_stop(const struct sr_dev_inst *sdi,
void *cb_data)
{
- struct dev_context *devc;
struct sr_datafeed_packet packet;
- sr_dbg("la8: Stopping acquisition.");
+ (void)sdi;
+ sr_dbg("la8: Stopping acquisition.");
sr_source_remove(-1);
- if (!(devc = sdi->priv)) {
- sr_err("la8: %s: sdi->priv was NULL", __func__);
- return SR_ERR_BUG;
- }
-
/* Send end packet to the session bus. */
sr_dbg("la8: Sending SR_DF_END.");
packet.type = SR_DF_END;