Can now control SSL cert verfication from in-engine
This commit is contained in:
@@ -55,17 +55,15 @@ static PADDRINFOA find_good_addr(PADDRINFOA addrinfo) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
static SOCKET open_connection(std::string_view target, std::string &err) {
|
||||
static SOCKET open_connection(const char *host, const char *port, std::string &err) {
|
||||
PADDRINFOA addrs = nullptr;
|
||||
PADDRINFOA goodaddr = nullptr;
|
||||
SOCKET sock = INVALID_SOCKET;
|
||||
std::string_view host, port;
|
||||
|
||||
err.clear();
|
||||
util::split_host_port(target, host, port);
|
||||
int status = getaddrinfo(host.data(), port.data(), nullptr, &addrs);
|
||||
int status = getaddrinfo(host, port, nullptr, &addrs);
|
||||
while (status == WSATRY_AGAIN) {
|
||||
status = getaddrinfo(host.data(), port.data(), nullptr, &addrs);
|
||||
status = getaddrinfo(host, port, nullptr, &addrs);
|
||||
}
|
||||
if (status == WSAHOST_NOT_FOUND) {
|
||||
err = "host not found";
|
||||
|
||||
Reference in New Issue
Block a user