un-deprecate the endpoint field in listen_failed_alert

This commit is contained in:
arvidn 2016-02-07 02:12:58 -05:00
parent df353bc3f9
commit f8a53d17ec
2 changed files with 0 additions and 6 deletions

View File

@ -1298,10 +1298,8 @@ namespace libtorrent
// the type of listen socket this alert refers to.
socket_type_t sock_type;
#ifndef TORRENT_NO_DEPRECATE
// the address and port libtorrent attempted to listen on
tcp::endpoint endpoint;
#endif
private:
aux::stack_allocator const& m_alloc;

View File

@ -787,14 +787,12 @@ namespace libtorrent {
"SSL/uTP"
};
#ifndef TORRENT_NO_DEPRECATE
tcp::endpoint parse_interface(std::string const& iface, int port)
{
// ignore errors
error_code ec;
return tcp::endpoint(address::from_string(iface, ec), port);
}
#endif
}
listen_failed_alert::listen_failed_alert(
@ -808,9 +806,7 @@ namespace libtorrent {
, operation(op)
, port(prt)
, sock_type(t)
#ifndef TORRENT_NO_DEPRECATE
, endpoint(parse_interface(iface, prt))
#endif
, m_alloc(alloc)
, m_interface_idx(alloc.copy_string(iface))
{}