src: Remove unnecessary uses of boost::cref in make_shared and replace boost::cref/boost::ref with just cref/ref
In some cases, due to argument-dependent lookup, it is necessary to use
ndn::ref, instead of just ref.
Change-Id: I682180a007609535855f77511b49622154ad4f11
Refs: #1591
diff --git a/daemon/face/unix-stream-channel.cpp b/daemon/face/unix-stream-channel.cpp
index efdf700..d64f333 100644
--- a/daemon/face/unix-stream-channel.cpp
+++ b/daemon/face/unix-stream-channel.cpp
@@ -96,7 +96,7 @@
throw Error(m_endpoint.path() + " already exists and is not a socket file");
}
- m_acceptor = make_shared<stream_protocol::acceptor>(boost::ref(getGlobalIoService()));
+ m_acceptor = make_shared<stream_protocol::acceptor>(ref(getGlobalIoService()));
m_acceptor->open();
m_acceptor->bind(m_endpoint);
m_acceptor->listen(backlog);
@@ -108,7 +108,7 @@
}
shared_ptr<stream_protocol::socket> clientSocket =
- make_shared<stream_protocol::socket>(boost::ref(getGlobalIoService()));
+ make_shared<stream_protocol::socket>(ref(getGlobalIoService()));
m_acceptor->async_accept(*clientSocket,
bind(&UnixStreamChannel::handleSuccessfulAccept, this,
@@ -134,7 +134,7 @@
NFD_LOG_DEBUG("[" << m_endpoint << "] << Incoming connection");
shared_ptr<stream_protocol::socket> clientSocket =
- make_shared<stream_protocol::socket>(boost::ref(getGlobalIoService()));
+ make_shared<stream_protocol::socket>(ref(getGlobalIoService()));
// prepare accepting the next connection
m_acceptor->async_accept(*clientSocket,
@@ -142,7 +142,7 @@
boost::asio::placeholders::error, clientSocket,
onFaceCreated, onAcceptFailed));
- shared_ptr<UnixStreamFace> face = make_shared<UnixStreamFace>(boost::cref(socket));
+ shared_ptr<UnixStreamFace> face = make_shared<UnixStreamFace>(socket);
onFaceCreated(face);
}