Changeset 3745
- Timestamp:
- 08/27/08 21:11:48
- Files:
-
- trunk/ChangeLog (modified) (1 diff)
- trunk/libtinymail-camel/camel-lite/camel/camel-tcp-stream-openssl.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/ChangeLog
r3743 r3745 1 2008-08-27 Martin Bonnin <martinbonnin@gmail.com> 2 3 * This removes the "Warning: invalid file descriptor -1 in syscall 4 close()" seen when using valgrind with tinymail. stream_close() is 5 called twice in a row on the same stream. There might be more 6 implications than just this valgrind warning, full details here 7 http://www.tinymail.org/trac/tinymail/ticket/62#preview 8 1 9 2008-08-22 Philip Van Hoof <philip@codeminded.be> 2 10 trunk/libtinymail-camel/camel-lite/camel/camel-tcp-stream-openssl.c
r3697 r3745 692 692 stream_close (CamelStream *stream) 693 693 { 694 close_ssl_connection (((CamelTcpStreamSSL *)stream)->priv->ssl); 695 ((CamelTcpStreamSSL *)stream)->priv->ssl = NULL; 696 697 if (close (((CamelTcpStreamSSL *)stream)->priv->sockfd) == -1) 698 return -1; 699 700 ((CamelTcpStreamSSL *)stream)->priv->sockfd = -1; 694 if( ((CamelTcpStreamSSL *)stream)->priv->ssl ){ 695 close_ssl_connection (((CamelTcpStreamSSL *)stream)->priv->ssl); 696 ((CamelTcpStreamSSL *)stream)->priv->ssl = NULL; 697 } 698 699 if( ((CamelTcpStreamSSL *)stream)->priv->sockfd != -1 ){ 700 if (close (((CamelTcpStreamSSL *)stream)->priv->sockfd) == -1) 701 return -1; 702 703 ((CamelTcpStreamSSL *)stream)->priv->sockfd = -1; 704 } 705 701 706 return 0; 702 707 }
