aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/cli/tls_client.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cli/tls_client.cpp b/src/cli/tls_client.cpp
index 2e690feab..1379b49be 100644
--- a/src/cli/tls_client.cpp
+++ b/src/cli/tls_client.cpp
@@ -308,13 +308,13 @@ class TLS_Client final : public Command, public Botan::TLS::Callbacks
break;
}
+ ::freeaddrinfo(res);
+
if(rp == nullptr) // no address succeeded
{
throw CLI_Error("connect failed");
}
- ::freeaddrinfo(res);
-
return fd;
}