From: Wayne Davison Date: Sat, 17 Oct 2009 16:09:27 +0000 (-0700) Subject: Fix check for an empty output buffer and limit to flist_eof. X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/commitdiff_plain/1ec57e4ddcea665d04e780041fb0d1d8885bfed3 Fix check for an empty output buffer and limit to flist_eof. --- diff --git a/io.c b/io.c index 7c50d5af..610a802b 100644 --- a/io.c +++ b/io.c @@ -1197,7 +1197,8 @@ void io_end_buffering_out(BOOL free_buffers) void maybe_flush_socket(int important) { - if (iobuf.out.buf && iobuf.out.len && (important || time(NULL) - last_io_out >= 5)) + if (flist_eof && iobuf.out.buf && iobuf.out.len > iobuf.out_empty_len + && (important || time(NULL) - last_io_out >= 5)) io_flush(NORMAL_FLUSH); }