From 06eeab272d89e6491b48c7bed4d97bb68b821946 Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Tue, 27 Jul 2010 18:46:04 -0700 Subject: usrp: gain group should not try to set gain elements if there are none --- host/lib/gain_group.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/host/lib/gain_group.cpp b/host/lib/gain_group.cpp index 3ae9a285e..5a14fa96f 100644 --- a/host/lib/gain_group.cpp +++ b/host/lib/gain_group.cpp @@ -70,6 +70,7 @@ public: void set_value(float gain){ std::vector all_fcns = get_all_fcns(); + if (all_fcns.size() == 0) return; //nothing to set! //get the max step size among the gains float max_step = 0; -- cgit v1.2.3