]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
mod_ssl: follow up to r1723122.
authorYann Ylavic <ylavic@apache.org>
Tue, 5 Jan 2016 18:06:23 +0000 (18:06 +0000)
committerYann Ylavic <ylavic@apache.org>
Tue, 5 Jan 2016 18:06:23 +0000 (18:06 +0000)
Coalesce when (subsequent brigade's) data bucket is not last (likely followed
by FLUSH or EOS) but we have buffered data already.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1723143 13f79535-47bb-0310-9956-ffa450edef68

modules/ssl/ssl_engine_io.c

index dc998462b084c26e1cba4ab250c5a4820b89b796..8c6d8ac97e9e39ace58c89e1129d7652208b4b76 100644 (file)
@@ -1567,11 +1567,12 @@ static apr_status_t ssl_io_filter_coalesce(ap_filter_t *f,
     /* Coalesce the prefix, if:
      * a) more than one bucket is found to coalesce, or
      * b) the brigade contains only a single data bucket, or
-     * c)
+     * c) the data bucket is not last but we have buffered data already.
      */
     if (bytes > 0
         && (count > 1
-            || (count == 1 && endb == APR_BRIGADE_SENTINEL(bb)))) {
+            || (endb == APR_BRIGADE_SENTINEL(bb))
+            || (ctx && ctx->bytes > 0))) {
         /* If coalescing some bytes, ensure a context has been
          * created. */
         if (!ctx) {