diff options
Diffstat (limited to 'gr-blocks/lib/socket_pdu_impl.cc')
-rw-r--r-- | gr-blocks/lib/socket_pdu_impl.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gr-blocks/lib/socket_pdu_impl.cc b/gr-blocks/lib/socket_pdu_impl.cc index cd74d60603..bdbe1eb2d2 100644 --- a/gr-blocks/lib/socket_pdu_impl.cc +++ b/gr-blocks/lib/socket_pdu_impl.cc @@ -89,7 +89,7 @@ socket_pdu_impl::socket_pdu_impl(std::string type, start_tcp_accept(); set_msg_handler(pdu::pdu_port_id(), - boost::bind(&socket_pdu_impl::tcp_server_send, this, _1)); + [this](pmt::pmt_t msg) { this->tcp_server_send(msg); }); } else if (type == "TCP_CLIENT") { boost::system::error_code error = boost::asio::error::host_not_found; d_tcp_socket.reset(new boost::asio::ip::tcp::socket(d_io_service)); @@ -99,7 +99,7 @@ socket_pdu_impl::socket_pdu_impl(std::string type, d_tcp_socket->set_option(boost::asio::ip::tcp::no_delay(d_tcp_no_delay)); set_msg_handler(pdu::pdu_port_id(), - boost::bind(&socket_pdu_impl::tcp_client_send, this, _1)); + [this](pmt::pmt_t msg) { this->tcp_client_send(msg); }); d_tcp_socket->async_read_some( boost::asio::buffer(d_rxbuf), @@ -119,7 +119,7 @@ socket_pdu_impl::socket_pdu_impl(std::string type, boost::asio::placeholders::bytes_transferred)); set_msg_handler(pdu::pdu_port_id(), - boost::bind(&socket_pdu_impl::udp_send, this, _1)); + [this](pmt::pmt_t msg) { this->udp_send(msg); }); } else if (type == "UDP_CLIENT") { d_udp_socket.reset( new boost::asio::ip::udp::socket(d_io_service, d_udp_endpoint)); @@ -132,7 +132,7 @@ socket_pdu_impl::socket_pdu_impl(std::string type, boost::asio::placeholders::bytes_transferred)); set_msg_handler(pdu::pdu_port_id(), - boost::bind(&socket_pdu_impl::udp_send, this, _1)); + [this](pmt::pmt_t msg) { this->udp_send(msg); }); } else throw std::runtime_error("gr::blocks:socket_pdu: unknown socket type"); |