dovecot-2.1: lib-ssl-iostream: When plain_output's buffer is ful...

dovecot at dovecot.org dovecot at dovecot.org
Wed Sep 7 11:03:05 EEST 2011


details:   http://hg.dovecot.org/dovecot-2.1/rev/d96c03d7eeef
changeset: 13418:d96c03d7eeef
user:      Timo Sirainen <tss at iki.fi>
date:      Wed Sep 07 11:02:55 2011 +0300
description:
lib-ssl-iostream: When plain_output's buffer is full, set it flush-pending.
This fixes hangs when the output buffer got full.

diffstat:

 src/lib-ssl-iostream/iostream-openssl.c |  2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diffs (12 lines):

diff -r 977dcd541f69 -r d96c03d7eeef src/lib-ssl-iostream/iostream-openssl.c
--- a/src/lib-ssl-iostream/iostream-openssl.c	Wed Sep 07 10:59:35 2011 +0300
+++ b/src/lib-ssl-iostream/iostream-openssl.c	Wed Sep 07 11:02:55 2011 +0300
@@ -268,6 +268,8 @@
 		if (bytes > max_bytes) {
 			if (max_bytes == 0) {
 				/* wait until output buffer clears */
+				o_stream_set_flush_pending(ssl_io->plain_output,
+							   TRUE);
 				break;
 			}
 			bytes = max_bytes;


More information about the dovecot-cvs mailing list