diff options
Diffstat (limited to 'host/lib')
-rw-r--r-- | host/lib/usrp/usrp2/usrp2_impl.cpp | 4 | ||||
-rw-r--r-- | host/lib/usrp/usrp2/usrp2_impl.hpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/host/lib/usrp/usrp2/usrp2_impl.cpp b/host/lib/usrp/usrp2/usrp2_impl.cpp index bdf8cc55b..85d73e83a 100644 --- a/host/lib/usrp/usrp2/usrp2_impl.cpp +++ b/host/lib/usrp/usrp2/usrp2_impl.cpp @@ -26,7 +26,7 @@ using namespace uhd::usrp; using namespace uhd::transport; namespace asio = boost::asio; -STATIC_BLOCK(register_device){ +STATIC_BLOCK(register_usrp2_device){ device::register_device(&usrp2::discover, &usrp2::make); } @@ -36,6 +36,8 @@ STATIC_BLOCK(register_device){ uhd::device_addrs_t usrp2::discover(const device_addr_t &hint){ device_addrs_t usrp2_addrs; + if (not hint.has_key("addr")) return usrp2_addrs; + //create a udp transport to communicate //TODO if an addr is not provided, search all interfaces? std::string ctrl_port = boost::lexical_cast<std::string>(USRP2_UDP_CTRL_PORT); diff --git a/host/lib/usrp/usrp2/usrp2_impl.hpp b/host/lib/usrp/usrp2/usrp2_impl.hpp index 70420fd49..55ac0b192 100644 --- a/host/lib/usrp/usrp2/usrp2_impl.hpp +++ b/host/lib/usrp/usrp2/usrp2_impl.hpp @@ -86,8 +86,6 @@ private: */ class usrp2_impl : public uhd::device{ public: - typedef boost::shared_ptr<usrp2_impl> sptr; - /*! * Create a new usrp2 impl base. * \param ctrl_transport the udp transport for control |