From e75988f38402b2c538dd1eae2a43c2c96a446666 Mon Sep 17 00:00:00 2001 From: dreamsourcelabTAI Date: Wed, 24 May 2023 19:07:55 +0800 Subject: [PATCH] If have no data, do not to add the decode task --- DSView/pv/sigsession.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/DSView/pv/sigsession.cpp b/DSView/pv/sigsession.cpp index 437526a4..ae83f3b4 100644 --- a/DSView/pv/sigsession.cpp +++ b/DSView/pv/sigsession.cpp @@ -1400,11 +1400,14 @@ namespace pv // Make a list of all the probes std::vector all_probes; - for (const GSList *i = dec->channels; i; i = i->next) - all_probes.push_back((const srd_channel *)i->data); - for (const GSList *i = dec->opt_channels; i; i = i->next) + for (const GSList *i = dec->channels; i; i = i->next){ all_probes.push_back((const srd_channel *)i->data); + } + + for (const GSList *i = dec->opt_channels; i; i = i->next){ + all_probes.push_back((const srd_channel *)i->data); + } decoder_stack->stack().front()->set_probes(probes); @@ -1452,7 +1455,7 @@ namespace pv _decode_traces.push_back(trace); // add decode task from ui - if (!silent) + if (!silent && have_view_data()) { add_decode_task(trace); }