X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=mutt_socket.c;h=9029b3e11874f876ba2c4c743ce4eae783a6d4f4;hp=869917d83eeefe6f0ac9c0cdc61ffa469ca12528;hb=103addea87100ee814eaad2a8cf7d944936ab582;hpb=ba5e3af4ea19e1d20c80941c077039871ec84258 diff --git a/mutt_socket.c b/mutt_socket.c index 869917d..9029b3e 100644 --- a/mutt_socket.c +++ b/mutt_socket.c @@ -237,10 +237,8 @@ CONNECTION *mutt_conn_find (const CONNECTION * start, const ACCOUNT * account) if (Tunnel && *Tunnel) mutt_tunnel_socket_setup (conn); else if (account->flags & M_ACCT_SSL) { -#ifdef USE_SSL - ssl_socket_setup (conn); -#elif USE_GNUTLS - if (mutt_gnutls_socket_setup (conn) < 0) { +#if defined (USE_SSL) || defined (USE_GNUTLS) + if (mutt_ssl_socket_setup (conn) < 0) { mutt_socket_free (conn); return NULL; } @@ -411,6 +409,7 @@ int raw_socket_open (CONNECTION * conn) if (rc) { mutt_error (_("Could not find the host \"%s\""), conn->account.host); + mutt_sleep (2); return -1; } @@ -476,6 +475,7 @@ int raw_socket_open (CONNECTION * conn) if (fd >= 0) { if ((rc = socket_connect (fd, (struct sockaddr *) &sin)) == 0) { + fcntl (fd, F_SETFD, FD_CLOEXEC); conn->fd = fd; break; }