aboutsummaryrefslogtreecommitdiffstats
path: root/host
diff options
context:
space:
mode:
authorAndrej Rode <andrej.rode@ettus.com>2016-12-16 17:01:31 -0800
committerMartin Braun <martin.braun@ettus.com>2017-01-12 15:15:37 -0800
commit2a3b85a892c3f6f90d5e828d1f406c3d39804023 (patch)
tree21c53d0a20752743e46ac095517930227e97016a /host
parent94a043ab5b1f4e719ba841fc94de47c785a17d07 (diff)
downloaduhd-2a3b85a892c3f6f90d5e828d1f406c3d39804023.tar.gz
uhd-2a3b85a892c3f6f90d5e828d1f406c3d39804023.tar.bz2
uhd-2a3b85a892c3f6f90d5e828d1f406c3d39804023.zip
experts: remove delete after throw
Diffstat (limited to 'host')
-rw-r--r--host/lib/experts/expert_container.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/host/lib/experts/expert_container.cpp b/host/lib/experts/expert_container.cpp
index 1d945aa42..b9c78f9f5 100644
--- a/host/lib/experts/expert_container.cpp
+++ b/host/lib/experts/expert_container.cpp
@@ -294,11 +294,11 @@ protected:
EX_LOG(0, str(boost::format("add_data_node(%s)") % data_node->get_name()));
if (data_node->get_class() == CLASS_WORKER) {
throw uhd::runtime_error("Supplied node " + data_node->get_name() + " is not a data/property node.");
- delete data_node;
+ // Throw leaves data_node undeleted
}
if (_datanode_map.find(data_node->get_name()) != _datanode_map.end()) {
throw uhd::runtime_error("Data node with name " + data_node->get_name() + " already exists");
- delete data_node;
+ // Throw leaves data node undeleted
}
try {
@@ -335,11 +335,9 @@ protected:
EX_LOG(0, str(boost::format("add_worker(%s)") % worker->get_name()));
if (worker->get_class() != CLASS_WORKER) {
throw uhd::runtime_error("Supplied node " + worker->get_name() + " is not a worker node.");
- delete worker;
}
if (_worker_map.find(worker->get_name()) != _worker_map.end()) {
throw uhd::runtime_error("Resolver with name " + worker->get_name() + " already exists.");
- delete worker;
}
try {