[dovecot-cvs] dovecot/src/lib istream.c,1.8,1.9

cras at procontrol.fi cras at procontrol.fi
Sun Apr 27 20:09:04 EEST 2003


Update of /home/cvs/dovecot/src/lib
In directory danu:/tmp/cvs-serv4418

Modified Files:
	istream.c 
Log Message:
i_stream_seek() broke stream if read limit was set.



Index: istream.c
===================================================================
RCS file: /home/cvs/dovecot/src/lib/istream.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- istream.c	20 Mar 2003 22:31:36 -0000	1.8
+++ istream.c	27 Apr 2003 16:09:02 -0000	1.9
@@ -105,8 +105,7 @@
 		stream->v_limit = v_offset;
 		max_pos = v_offset - stream->v_offset + _stream->skip;
 		if (_stream->pos > max_pos) {
-			if (_stream->high_pos == 0)
-				_stream->high_pos = _stream->pos;
+			_stream->high_pos = _stream->pos;
 			_stream->pos = max_pos;
 		}
 	}
@@ -166,6 +165,7 @@
 	if (stream->closed)
 		return;
 
+	_stream->high_pos = 0;
 	_stream->seek(_stream, v_offset);
 }
 




More information about the dovecot-cvs mailing list