1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-12 09:18:10 +03:00

r426: fixed bug noticed by wim.delvaux@adaptiveplanet.com in handling of timeout in socket connections

This commit is contained in:
Andrew Tridgell 2004-04-30 13:58:23 +00:00 committed by Gerald (Jerry) Carter
parent d98a36b459
commit 88278b24de

View File

@ -741,6 +741,7 @@ int open_socket_out(int type, struct in_addr *addr, int port ,int timeout)
if (ret < 0 && (errno == EINPROGRESS || errno == EALREADY ||
errno == EAGAIN) && (connect_loop < timeout) ) {
smb_msleep(connect_loop);
timeout -= connect_loop;
connect_loop += increment;
if (increment < 250) {
/* After 8 rounds we end up at a max of 255 msec */