dovecot-2.2: lib: If i_stream_seek() works by reading forward an...
dovecot at dovecot.org
dovecot at dovecot.org
Sat Oct 25 22:01:33 UTC 2014
details: http://hg.dovecot.org/dovecot-2.2/rev/503b4b1b7aa1
changeset: 18020:503b4b1b7aa1
user: Timo Sirainen <tss at iki.fi>
date: Sun Oct 26 01:00:36 2014 +0300
description:
lib: If i_stream_seek() works by reading forward and read() fails, don't override the error message.
diffstat:
src/lib/istream.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diffs (14 lines):
diff -r d35288713625 -r 503b4b1b7aa1 src/lib/istream.c
--- a/src/lib/istream.c Sun Oct 26 00:08:05 2014 +0300
+++ b/src/lib/istream.c Sun Oct 26 01:00:36 2014 +0300
@@ -749,6 +749,10 @@
available = stream->pos - stream->skip;
if (available == 0) {
+ if (stream->istream.stream_errno != 0) {
+ /* read failed */
+ return;
+ }
io_stream_set_error(&stream->iostream,
"Can't seek to offset %"PRIuUOFF_T
", because we have data only up to offset %"
More information about the dovecot-cvs
mailing list