face: Remove unnecessary use of DNS resolver in (Udp|Tcp|WebSocket)Factory
Change-Id: Idbc743fe4c7d567a09acccef98fe6de26f8295f0
Refs: #2422
diff --git a/daemon/face/tcp-factory.cpp b/daemon/face/tcp-factory.cpp
index 0a152b1..dc7e369 100644
--- a/daemon/face/tcp-factory.cpp
+++ b/daemon/face/tcp-factory.cpp
@@ -27,7 +27,6 @@
#include "core/logger.hpp"
#include "core/network-interface.hpp"
#include "core/global-io.hpp"
-#include <ndn-cxx/util/dns.hpp>
NFD_LOG_INIT("TcpFactory");
@@ -109,10 +108,10 @@
}
shared_ptr<TcpChannel>
-TcpFactory::createChannel(const std::string& localHost, const std::string& localPort)
+TcpFactory::createChannel(const std::string& localIp, const std::string& localPort)
{
- tcp::Endpoint endpoint(ndn::dns::syncResolve(localHost, getGlobalIoService()),
- boost::lexical_cast<uint16_t>(localPort));
+ using namespace boost::asio::ip;
+ tcp::Endpoint endpoint(address::from_string(localIp), boost::lexical_cast<uint16_t>(localPort));
return createChannel(endpoint);
}