diff options
author | Josh Blum <josh@joshknows.com> | 2011-08-31 15:51:23 -0700 |
---|---|---|
committer | Josh Blum <josh@joshknows.com> | 2011-08-31 16:08:09 -0700 |
commit | dfb30a5d35c4dfeac567c250b792e5d9a68e8a69 (patch) | |
tree | f2b4643b744ce97bdda018b71d34f280c55655fd /host/lib/usrp | |
parent | bcb76b5d5d29626a879250d8ad58e9219b2928c5 (diff) | |
download | uhd-dfb30a5d35c4dfeac567c250b792e5d9a68e8a69.tar.gz uhd-dfb30a5d35c4dfeac567c250b792e5d9a68e8a69.tar.bz2 uhd-dfb30a5d35c4dfeac567c250b792e5d9a68e8a69.zip |
usrp2: made iface deconstructor safe (unlock can throw)release_003_002_003
Diffstat (limited to 'host/lib/usrp')
-rw-r--r-- | host/lib/usrp/usrp2/usrp2_iface.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/host/lib/usrp/usrp2/usrp2_iface.cpp b/host/lib/usrp/usrp2/usrp2_iface.cpp index aaa5acbd5..d91dd0e40 100644 --- a/host/lib/usrp/usrp2/usrp2_iface.cpp +++ b/host/lib/usrp/usrp2/usrp2_iface.cpp @@ -21,6 +21,7 @@ #include <uhd/exception.hpp> #include <uhd/utils/msg.hpp> #include <uhd/utils/tasks.hpp> +#include <uhd/utils/safe_call.hpp> #include <uhd/types/dict.hpp> #include <boost/thread.hpp> #include <boost/foreach.hpp> @@ -96,9 +97,9 @@ public: mb_eeprom = mboard_eeprom_t(*this, mboard_eeprom_t::MAP_N100); } - ~usrp2_iface_impl(void){ + ~usrp2_iface_impl(void){UHD_SAFE_CALL( this->lock_device(false); - } + )} /*********************************************************************** * Device locking |