[dovecot-cvs] dovecot/src/imap client.c,1.54,1.55
cras at dovecot.org
cras at dovecot.org
Sun May 29 13:50:47 EEST 2005
Update of /var/lib/cvs/dovecot/src/imap
In directory talvi:/tmp/cvs-serv5839
Modified Files:
client.c
Log Message:
Changed output handler to work a bit differently to avoid useless
io_remove/io_add calls.
Index: client.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/imap/client.c,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- client.c 26 Apr 2005 10:43:54 -0000 1.54
+++ client.c 29 May 2005 10:50:43 -0000 1.55
@@ -411,12 +411,14 @@
o_stream_cork(client->output);
client->output_pending = TRUE;
finished = cmd->func(cmd) || cmd->param_error;
- o_stream_uncork(client->output);
- /* a bit kludgy. normally we would want to get back here, but IDLE
- is a special case which has command pending but without necessarily
- anything to write. */
- ret = finished || !client->output_pending;
+ /* a bit kludgy check. normally we would want to get back to this
+ output handler, but IDLE is a special case which has command
+ pending but without necessarily anything to write. */
+ if (!finished && client->output_pending)
+ o_stream_set_flush_pending(client->output, TRUE);
+
+ o_stream_uncork(client->output);
if (finished) {
/* command execution was finished */
More information about the dovecot-cvs
mailing list