From: Soeren Apel Date: Fri, 22 May 2020 22:05:12 +0000 (+0200) Subject: Make sure get_time_extents() uses a signal that data was acquired for X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=0bb3dd25421a8638afb881d46799a13378d3f00b;p=pulseview.git Make sure get_time_extents() uses a signal that data was acquired for --- diff --git a/pv/views/trace/view.cpp b/pv/views/trace/view.cpp index cfafdc08..df589675 100644 --- a/pv/views/trace/view.cpp +++ b/pv/views/trace/view.cpp @@ -928,7 +928,9 @@ pair View::get_time_extents() const if (signals_.size() == 0) return make_pair(0, 0); - data.push_back(signals_.front()->data()); + for (shared_ptr s : signals_) + if (s->data()->segments().size() > 0) + data.push_back(s->data()); for (const shared_ptr& d : data) { const vector< shared_ptr > segments = d->segments();