changeset 2641:e357ebb3137b HEAD

Memory leak fixes
author Timo Sirainen <tss@iki.fi>
date Mon, 20 Sep 2004 02:46:33 +0300
parents 66cad846df36
children 663fc1f2aaf5
files src/lib-index/mail-cache-compress.c src/lib-index/mail-index-transaction.c src/lib-storage/index/index-search.c src/lib-storage/index/mbox/istream-raw-mbox.c
diffstat 4 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-index/mail-cache-compress.c	Mon Sep 20 02:23:08 2004 +0300
+++ b/src/lib-index/mail-cache-compress.c	Mon Sep 20 02:46:33 2004 +0300
@@ -188,6 +188,7 @@
 
 	hdr.used_file_size = output->offset;
 	buffer_free(ctx.buffer);
+	buffer_free(ctx.field_seen);
 
 	o_stream_seek(output, 0);
 	o_stream_send(output, &hdr, sizeof(hdr));
--- a/src/lib-index/mail-index-transaction.c	Mon Sep 20 02:23:08 2004 +0300
+++ b/src/lib-index/mail-index-transaction.c	Mon Sep 20 02:46:33 2004 +0300
@@ -46,6 +46,7 @@
 			if (recs[i] != NULL)
 				buffer_free(recs[i]);
 		}
+		buffer_free(t->extra_rec_updates);
 	}
 
 	if (t->appends != NULL)
--- a/src/lib-storage/index/index-search.c	Mon Sep 20 02:23:08 2004 +0300
+++ b/src/lib-storage/index/index-search.c	Mon Sep 20 02:46:33 2004 +0300
@@ -783,6 +783,7 @@
 	if (ctx->hdr_pool != NULL)
 		pool_unref(ctx->hdr_pool);
 
+	i_free(ctx->charset);
 	i_free(ctx);
 	return ret;
 }
--- a/src/lib-storage/index/mbox/istream-raw-mbox.c	Mon Sep 20 02:23:08 2004 +0300
+++ b/src/lib-storage/index/mbox/istream-raw-mbox.c	Mon Sep 20 02:46:33 2004 +0300
@@ -28,6 +28,9 @@
 {
 	struct raw_mbox_istream *rstream = (struct raw_mbox_istream *)stream;
 
+	i_free(rstream->sender);
+	i_free(rstream->next_sender);
+
 	i_stream_seek(rstream->input, rstream->istream.istream.v_offset);
 	i_stream_unref(rstream->input);
 }