mirror of
https://github.com/yhirose/cpp-httplib
synced 2024-11-21 14:29:10 -07:00
Fix #182
This commit is contained in:
parent
30d73051ee
commit
74e9a0d17e
1 changed files with 2 additions and 2 deletions
|
@ -646,8 +646,8 @@ socket_t create_socket(const char *host, int port, Fn fn,
|
|||
for (auto rp = result; rp; rp = rp->ai_next) {
|
||||
// Create a socket
|
||||
#ifdef _WIN32
|
||||
auto sock = WSASocket(rp->ai_family, rp->ai_socktype, rp->ai_protocol,
|
||||
nullptr, 0, WSA_FLAG_NO_HANDLE_INHERIT);
|
||||
auto sock = WSASocketW(rp->ai_family, rp->ai_socktype, rp->ai_protocol,
|
||||
nullptr, 0, WSA_FLAG_NO_HANDLE_INHERIT);
|
||||
#else
|
||||
auto sock = socket(rp->ai_family, rp->ai_socktype, rp->ai_protocol);
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue