mirror of
https://gitee.com/acl-dev/acl.git
synced 2024-11-30 10:57:34 +08:00
the IO timeout should be ms in acl_vstream_timed_connect()
This commit is contained in:
parent
d4a829102f
commit
98c8cc0abe
@ -196,12 +196,13 @@ ACL_VSTREAM *acl_vstream_timed_connect(const char *addr, int block_mode,
|
||||
}
|
||||
|
||||
client = acl_vstream_fdopen(connfd, ACL_VSTREAM_FLAG_RW,
|
||||
rw_bufsize, rw_timeout / 1000, ACL_VSTREAM_TYPE_SOCK);
|
||||
rw_bufsize, rw_timeout, ACL_VSTREAM_TYPE_SOCK);
|
||||
if (client == NULL) {
|
||||
acl_socket_close(connfd);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/* must set the IO timeout in ms unit */
|
||||
ACL_VSTREAM_SET_MS(client);
|
||||
|
||||
family = acl_getsockfamily(connfd);
|
||||
|
Loading…
Reference in New Issue
Block a user