[dovecot-cvs] dovecot/src/lib ostream-file.c,1.49,1.50
cras at dovecot.org
cras at dovecot.org
Sat May 28 14:31:22 EEST 2005
Update of /var/lib/cvs/dovecot/src/lib
In directory talvi:/tmp/cvs-serv5470
Modified Files:
ostream-file.c
Log Message:
Don't remove output handler if flush_pending is still set after callback.
Index: ostream-file.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib/ostream-file.c,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -d -r1.49 -r1.50
--- ostream-file.c 25 May 2005 11:39:57 -0000 1.49
+++ ostream-file.c 28 May 2005 11:31:19 -0000 1.50
@@ -361,13 +361,15 @@
else
ret = _flush(&fstream->ostream);
- if (ret > 0 && IS_STREAM_EMPTY(fstream) && fstream->io != NULL) {
+ if (ret == 0)
+ fstream->flush_pending = TRUE;
+
+ if (!fstream->flush_pending &&
+ IS_STREAM_EMPTY(fstream) && fstream->io != NULL) {
/* all sent */
io_remove(fstream->io);
fstream->io = NULL;
}
- if (ret == 0)
- fstream->flush_pending = TRUE;
o_stream_unref(&fstream->ostream.ostream);
}
More information about the dovecot-cvs
mailing list