]> Pileus Git - ~andy/fetchmail/commitdiff
Properly shut down SSL connections. Berlios Patch #647 by Arkadiusz Miśkiewicz.
authorMatthias Andree <matthias.andree@gmx.de>
Fri, 21 Oct 2005 09:15:09 +0000 (09:15 -0000)
committerMatthias Andree <matthias.andree@gmx.de>
Fri, 21 Oct 2005 09:15:09 +0000 (09:15 -0000)
svn path=/trunk/; revision=4360

NEWS
socket.c

diff --git a/NEWS b/NEWS
index 6c678024abb021a18a6493f579fa3bbf5ad2900d..a9fad21fd37ad6847bb6b85b88c15e5c24116fe6 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -229,6 +229,8 @@ fetchmail 6.3.0 (not yet released officially):
   also offers MSN and NTLM, suggested by Yves Boisjoly. Matthias Andree
 * fetchmailconf now (as of 1.49) writes its version to the comment of the
   saved run control file. Matthias Andree
+* Properly shut down SSL connections. Berlios Patch #647 by Arkadiusz
+  Miśkiewicz. (MA)
 
 # INTERNAL CHANGES
 * Switched to automake. Matthias Andree.
index 411d24f7097994c50cf07342149e5f0fd6409a90..2383e965909d54eef5e7158315767500d105c718 100644 (file)
--- a/socket.c
+++ b/socket.c
@@ -855,6 +855,7 @@ int SSLOpen(int sock, char *mycert, char *mykey, char *myproto, int certck, char
                if (fingerprint != NULL || certck) {
                        if( NULL != SSLGetContext( sock ) ) {
                                /* Clean up the SSL stack */
+                               SSL_shutdown( _ssl_context[sock] );
                                SSL_free( _ssl_context[sock] );
                                _ssl_context[sock] = NULL;
                        }
@@ -872,6 +873,7 @@ int SockClose(int sock)
 #ifdef SSL_ENABLE
     if( NULL != SSLGetContext( sock ) ) {
         /* Clean up the SSL stack */
+        SSL_shutdown( _ssl_context[sock] );
         SSL_free( _ssl_context[sock] );
         _ssl_context[sock] = NULL;
     }