dovecot-2.0: istream-mail-stats: Don't double-reference parent s...

dovecot at dovecot.org dovecot at dovecot.org
Mon Aug 10 20:50:06 EEST 2009


details:   http://hg.dovecot.org/dovecot-2.0/rev/815a76964e87
changeset: 9760:815a76964e87
user:      Timo Sirainen <tss at iki.fi>
date:      Mon Aug 10 13:49:31 2009 -0400
description:
istream-mail-stats: Don't double-reference parent stream.

diffstat:

1 file changed, 11 deletions(-)
src/lib-storage/index/istream-mail-stats.c |   11 -----------

diffs (32 lines):

diff -r ab4e247d326d -r 815a76964e87 src/lib-storage/index/istream-mail-stats.c
--- a/src/lib-storage/index/istream-mail-stats.c	Mon Aug 10 13:36:01 2009 -0400
+++ b/src/lib-storage/index/istream-mail-stats.c	Mon Aug 10 13:49:31 2009 -0400
@@ -11,14 +11,6 @@ struct mail_stats_istream {
 	struct mail_private *mail;
 	unsigned int files_read_increased:1;
 };
-
-static void i_stream_mail_stats_destroy(struct iostream_private *stream)
-{
-	struct mail_stats_istream *mstream =
-		(struct mail_stats_istream *)stream;
-
-	i_stream_unref(&mstream->istream.parent);
-}
 
 static ssize_t
 i_stream_mail_stats_read_mail_stats(struct istream_private *stream)
@@ -63,13 +55,10 @@ struct istream *i_stream_create_mail_sta
 {
 	struct mail_stats_istream *mstream;
 
-	i_stream_ref(input);
-
 	mstream = i_new(struct mail_stats_istream, 1);
 	mstream->mail = mail;
 	mstream->istream.max_buffer_size = input->real_stream->max_buffer_size;
 
-	mstream->istream.iostream.destroy = i_stream_mail_stats_destroy;
 	mstream->istream.parent = input;
 	mstream->istream.read = i_stream_mail_stats_read_mail_stats;
 	mstream->istream.seek = i_stream_mail_stats_seek;


More information about the dovecot-cvs mailing list