Problem: socks_connecter_t does not set local address

Solution: query the local address and set it
This commit is contained in:
Simon Giesecke 2019-02-01 11:07:04 -05:00 committed by Simon Giesecke
parent 87082557f0
commit d8b5204f73

View File

@ -150,9 +150,9 @@ void zmq::socks_connecter_t::in_event ()
if (rc == -1)
error ();
else {
// TODO query the remote endpoint and pass it here
endpoint_uri_pair_t endpoint_pair =
make_unconnected_connect_endpoint_pair (_endpoint);
const endpoint_uri_pair_t endpoint_pair = endpoint_uri_pair_t (
get_socket_name<tcp_address_t> (_s, socket_end_local),
_endpoint, endpoint_type_connect);
// Create the engine object for this connection.
stream_engine_t *engine = new (std::nothrow)