Jpp 19.3.0-rc.1
the software that should make you happy
Loading...
Searching...
No Matches
recipients_handler.cc
Go to the documentation of this file.
2
3#include <boost/lexical_cast.hpp>
4
5/**
6 * \author cpellegrino
7 */
8
9boost::asio::ip::tcp::endpoint make_endpoint(const std::string& address)
10{
11 const size_t pos = address.find(":");
12 const std::string ip = address.substr(0, pos);
13 const unsigned short port = boost::lexical_cast<unsigned int>(address.substr(pos + 1));
14
15 return boost::asio::ip::tcp::endpoint(
16 boost::asio::ip::address::from_string(ip),
17 port);
18}
boost::asio::ip::tcp::endpoint make_endpoint(const std::string &address)