14 using boost::asio::ip::udp;
33 std::stringstream sPort;
36 udp::resolver::query query(udp::v4(), ip_address.c_str(), sPort.str());
38 boost::system::error_code ec;
42 if (ec.value() == boost::system::errc::success)
46 else if (ec.value() == boost::asio::error::invalid_argument)
62 boost::system::error_code ec;
65 if (ec.value() == boost::system::errc::success)
81 boost::system::error_code ec;
83 size_t msg_size =
socket_.receive(boost::asio::buffer(*msg), 0, ec);
84 msg->resize(msg_size);
86 if (ec.value() == boost::system::errc::success)
97 boost::system::error_code ec;
100 if (ec.value() == boost::system::errc::success)