mirror of
https://github.com/cuberite/libevent.git
synced 2025-09-22 10:51:00 -04:00
Update bench_httpclient.c
*fixed: socket_geterror instead of WSAGetLastError
This commit is contained in:
parent
4e9325e8dc
commit
cb96931236
@ -151,10 +151,7 @@ launch_request(void)
|
||||
}
|
||||
frob_socket(sock);
|
||||
if (connect(sock, (struct sockaddr*)&sin, sizeof(sin)) < 0) {
|
||||
int e = errno;
|
||||
#ifdef _WIN32
|
||||
e = WSAGetLastError();
|
||||
#endif
|
||||
int e = evutil_socket_geterror(sock);
|
||||
if (! EVUTIL_ERR_CONNECT_RETRIABLE(e)) {
|
||||
evutil_closesocket(sock);
|
||||
return -1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user