commit a6000c3ee18027abf15a97bd8eb986c4aafadf86 Author: Oswald Buddenhagen <o...@kde.org> Date: Sat Mar 19 19:40:50 2011 +0100
move responsibility for closing sockets on error to user the only user being imap and the first thing in imap_cancel_store() being a call to socket_close(), this code was pretty pointless anyway. src/socket.c | 4 ---- 1 files changed, 0 insertions(+), 4 deletions(-) diff --git a/src/socket.c b/src/socket.c index 7d0d24e..c8d1a57 100644 --- a/src/socket.c +++ b/src/socket.c @@ -377,8 +377,6 @@ socket_fill( conn_t *sock ) read( sock->fd, buf, len ); if (n <= 0) { socket_perror( "read", sock, n ); - close( sock->fd ); - sock->fd = -1; return -1; } else { sock->bytes += n; @@ -443,8 +441,6 @@ socket_write( conn_t *sock, char *buf, int len, ownership_t takeOwn ) free( buf ); if (n != len) { socket_perror( "write", sock, n ); - close( sock->fd ); - sock->fd = -1; return -1; } return 0; ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ isync-devel mailing list isync-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/isync-devel