提交 68338c7a 编写于 作者: J jai1 提交者: Matteo Merli

Getting the code to run with old boost asio (#197)

上级 d4610109
......@@ -136,17 +136,17 @@ void ClientConnection::handlePulsarConnected(const CommandConnected& cmdConnecte
}
/// The number of unacknowledged probes to send before considering the connection dead and notifying the application layer
typedef boost::asio::detail::socket_option::integer<BOOST_ASIO_OS_DEF(IPPROTO_TCP), TCP_KEEPCNT> tcp_keep_alive_count;
typedef boost::asio::detail::socket_option::integer<IPPROTO_TCP, TCP_KEEPCNT> tcp_keep_alive_count;
/// The interval between subsequential keepalive probes, regardless of what the connection has exchanged in the meantime
typedef boost::asio::detail::socket_option::integer<BOOST_ASIO_OS_DEF(IPPROTO_TCP), TCP_KEEPINTVL> tcp_keep_alive_interval;
typedef boost::asio::detail::socket_option::integer<IPPROTO_TCP, TCP_KEEPINTVL> tcp_keep_alive_interval;
/// The interval between the last data packet sent (simple ACKs are not considered data) and the first keepalive
/// probe; after the connection is marked to need keepalive, this counter is not used any further
#ifdef __APPLE__
typedef boost::asio::detail::socket_option::integer<BOOST_ASIO_OS_DEF(IPPROTO_TCP), TCP_KEEPALIVE> tcp_keep_alive_idle;
typedef boost::asio::detail::socket_option::integer<IPPROTO_TCP, TCP_KEEPALIVE> tcp_keep_alive_idle;
#else
typedef boost::asio::detail::socket_option::integer<BOOST_ASIO_OS_DEF(IPPROTO_TCP), TCP_KEEPIDLE> tcp_keep_alive_idle;
typedef boost::asio::detail::socket_option::integer<IPPROTO_TCP, TCP_KEEPIDLE> tcp_keep_alive_idle;
#endif
/*
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册