diff src/lib-index/mail-cache-compress.c @ 4070:71b8faa84ec6 HEAD

Added i_stream_destroy() and o_stream_destroy() and used them instead of *_stream_unref() where possible. Fixes at least one problem with io_remove() being called after socket was closed, which caused problems with epoll.
author Timo Sirainen <tss@iki.fi>
date Sun, 26 Feb 2006 12:04:59 +0200
parents 928229f8b3e6
children 9c3f19110538
line wrap: on
line diff
--- a/src/lib-index/mail-cache-compress.c	Sat Feb 25 13:29:05 2006 +0200
+++ b/src/lib-index/mail-cache-compress.c	Sun Feb 26 12:04:59 2006 +0200
@@ -216,7 +216,7 @@
 		errno = output->stream_errno;
 		mail_cache_set_syscall_error(cache, "o_stream_flush()");
 		(void)mail_index_transaction_rollback(&t);
-		o_stream_unref(&output);
+		o_stream_destroy(&output);
 		return -1;
 	}
 
@@ -225,7 +225,7 @@
 		(void)file_set_size(fd, MAIL_CACHE_INITIAL_SIZE);
 	}
 
-	o_stream_unref(&output);
+	o_stream_destroy(&output);
 
 	if (fdatasync(fd) < 0) {
 		mail_cache_set_syscall_error(cache, "fdatasync()");