demo: remove sources from session when done
This commit is contained in:
parent
a3508e33f9
commit
7fd3e85961
|
@ -518,13 +518,18 @@ static int hw_dev_acquisition_start(const struct sr_dev_inst *sdi,
|
||||||
static int hw_dev_acquisition_stop(const struct sr_dev_inst *sdi,
|
static int hw_dev_acquisition_stop(const struct sr_dev_inst *sdi,
|
||||||
void *cb_data)
|
void *cb_data)
|
||||||
{
|
{
|
||||||
|
struct dev_context *devc;
|
||||||
|
|
||||||
/* Avoid compiler warnings. */
|
/* Avoid compiler warnings. */
|
||||||
(void)sdi;
|
|
||||||
(void)cb_data;
|
(void)cb_data;
|
||||||
|
|
||||||
|
devc = sdi->priv;
|
||||||
|
|
||||||
/* Stop generate thread. */
|
/* Stop generate thread. */
|
||||||
thread_running = 0;
|
thread_running = 0;
|
||||||
|
|
||||||
|
sr_session_source_remove_channel(devc->channels[0]);
|
||||||
|
|
||||||
return SR_OK;
|
return SR_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue