From 7cf0d125d38bcf9f89894c2618235b0133ea273f Mon Sep 17 00:00:00 2001 From: Simon Giesecke Date: Thu, 7 Feb 2019 11:07:37 +0100 Subject: [PATCH] Problem: failed address resolution on TCP connect is not observable Solution: added TODO comment for now --- src/socks_connecter.cpp | 2 ++ src/tcp_connecter.cpp | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/socks_connecter.cpp b/src/socks_connecter.cpp index da6cfc24..9e068e8e 100644 --- a/src/socks_connecter.cpp +++ b/src/socks_connecter.cpp @@ -227,6 +227,8 @@ int zmq::socks_connecter_t::connect_to_proxy () _s = tcp_open_socket (_addr->address.c_str (), options, false, false, _addr->resolved.tcp_addr); if (_s == retired_fd) { + // TODO we should emit some event in this case! + LIBZMQ_DELETE (_addr->resolved.tcp_addr); return -1; } diff --git a/src/tcp_connecter.cpp b/src/tcp_connecter.cpp index 76ff9181..863f223f 100644 --- a/src/tcp_connecter.cpp +++ b/src/tcp_connecter.cpp @@ -177,6 +177,8 @@ int zmq::tcp_connecter_t::open () _s = tcp_open_socket (_addr->address.c_str (), options, false, true, _addr->resolved.tcp_addr); if (_s == retired_fd) { + // TODO we should emit some event in this case! + LIBZMQ_DELETE (_addr->resolved.tcp_addr); return -1; }