diff options
author | Costa Tsaousis <costa@netdata.cloud> | 2023-09-13 00:24:40 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-13 00:24:40 +0300 |
commit | e70e50815ba740edc64d9b3df31e5b79afbffd71 (patch) | |
tree | 13107ddf7f3c65f5e1e3bab84138a4427ee5b917 /libnetdata/socket | |
parent | 69894b1bd32de8c32c8f4880efff993fa9f496f0 (diff) |
streaming logs (#15948)
Diffstat (limited to 'libnetdata/socket')
-rw-r--r-- | libnetdata/socket/socket.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libnetdata/socket/socket.c b/libnetdata/socket/socket.c index e7d0b48076..a48b6ec53f 100644 --- a/libnetdata/socket/socket.c +++ b/libnetdata/socket/socket.c @@ -810,7 +810,7 @@ int connect_to_this_ip46(int protocol, int socktype, const char *host, uint32_t errno = 0; if(connect(fd, ai->ai_addr, ai->ai_addrlen) < 0) { if(errno == EALREADY || errno == EINPROGRESS) { - netdata_log_info("Waiting for connection to ip %s port %s to be established", hostBfr, servBfr); + internal_error(true, "Waiting for connection to ip %s port %s to be established", hostBfr, servBfr); // Convert 'struct timeval' to milliseconds for poll(): int timeout_milliseconds = timeout->tv_sec * 1000 + timeout->tv_usec / 1000; @@ -835,6 +835,7 @@ int connect_to_this_ip46(int protocol, int socktype, const char *host, uint32_t } else if (ret == 0) { // poll() timed out, the connection is not established within the specified timeout. + errno = 0; netdata_log_error("Timed out while connecting to '%s', port '%s'.", hostBfr, servBfr); close(fd); fd = -1; |