View | Details | Raw Unified | Return to bug 2918
Collapse All | Expand All

(-)sshconnect.c (-1 / +2 lines)
Lines 433-439 ssh_connect_direct(struct ssh *ssh, cons Link Here
433
    struct sockaddr_storage *hostaddr, u_short port, int family,
433
    struct sockaddr_storage *hostaddr, u_short port, int family,
434
    int connection_attempts, int *timeout_ms, int want_keepalive)
434
    int connection_attempts, int *timeout_ms, int want_keepalive)
435
{
435
{
436
	int on = 1;
436
	int on = 1, saved_timeout_ms = *timeout_ms;
437
	int oerrno, sock = -1, attempt;
437
	int oerrno, sock = -1, attempt;
438
	char ntop[NI_MAXHOST], strport[NI_MAXSERV];
438
	char ntop[NI_MAXHOST], strport[NI_MAXSERV];
439
	struct addrinfo *ai;
439
	struct addrinfo *ai;
Lines 477-482 ssh_connect_direct(struct ssh *ssh, cons Link Here
477
				continue;
477
				continue;
478
			}
478
			}
479
479
480
			*timeout_ms = saved_timeout_ms;
480
			if (timeout_connect(sock, ai->ai_addr, ai->ai_addrlen,
481
			if (timeout_connect(sock, ai->ai_addr, ai->ai_addrlen,
481
			    timeout_ms) >= 0) {
482
			    timeout_ms) >= 0) {
482
				/* Successful connection. */
483
				/* Successful connection. */

Return to bug 2918