dovecot: Fix to handling buffer full conditions.

dovecot at dovecot.org dovecot at dovecot.org
Sat Oct 20 19:17:04 EEST 2007


details:   http://hg.dovecot.org/dovecot/rev/b56ed305a8bf
changeset: 6557:b56ed305a8bf
user:      Timo Sirainen <tss at iki.fi>
date:      Sat Oct 20 19:11:20 2007 +0300
description:
Fix to handling buffer full conditions.

diffstat:

1 file changed, 3 insertions(+), 4 deletions(-)
src/lib/istream-limit.c |    7 +++----

diffs (17 lines):

diff -r f9a4bd4ea2bb -r b56ed305a8bf src/lib/istream-limit.c
--- a/src/lib/istream-limit.c	Sat Oct 20 17:06:33 2007 +0300
+++ b/src/lib/istream-limit.c	Sat Oct 20 19:11:20 2007 +0300
@@ -51,10 +51,9 @@ static ssize_t i_stream_limit_read(struc
 
 	stream->buffer = i_stream_get_data(lstream->input, &pos);
 	if (pos <= stream->pos) {
-		if ((ret = i_stream_read(lstream->input)) == -2) {
-			if (stream->skip == 0)
-				return -2;
-		}
+		if ((ret = i_stream_read(lstream->input)) == -2)
+			return -2;
+
 		stream->istream.stream_errno = lstream->input->stream_errno;
 		stream->istream.eof = lstream->input->eof;
 		stream->buffer = i_stream_get_data(lstream->input, &pos);


More information about the dovecot-cvs mailing list