diff --git a/apache2-mod_http2-issue-167.patch b/apache2-mod_http2-issue-167.patch new file mode 100644 index 0000000..fb75313 --- /dev/null +++ b/apache2-mod_http2-issue-167.patch @@ -0,0 +1,39 @@ +Index: httpd-2.4.34/modules/http2/h2_from_h1.c +=================================================================== +--- httpd-2.4.34.orig/modules/http2/h2_from_h1.c 2018-05-29 23:16:29.000000000 +0200 ++++ httpd-2.4.34/modules/http2/h2_from_h1.c 2019-02-27 12:39:19.503285243 +0100 +@@ -22,6 +22,8 @@ + #include + + #include ++#define AP_STATUS_IS_HEADER_ONLY(x) ((x) == HTTP_NO_CONTENT || \ ++ (x) == HTTP_NOT_MODIFIED) + #include + #include + #include +@@ -586,18 +588,20 @@ apr_status_t h2_filter_headers_out(ap_fi + } + } + +- if (r->header_only) { ++ if (r->header_only || AP_STATUS_IS_HEADER_ONLY(r->status)) { + ap_log_cerror(APLOG_MARK, APLOG_TRACE1, 0, f->c, +- "h2_task(%s): header_only, cleanup output brigade", ++ "h2_task(%s): headers only, cleanup output brigade", + task->id); + b = body_bucket? body_bucket : APR_BRIGADE_FIRST(bb); + while (b != APR_BRIGADE_SENTINEL(bb)) { + next = APR_BUCKET_NEXT(b); + if (APR_BUCKET_IS_EOS(b) || AP_BUCKET_IS_EOR(b)) { + break; +- } +- APR_BUCKET_REMOVE(b); +- apr_bucket_destroy(b); ++ } ++ if (!H2_BUCKET_IS_HEADERS(b)) { ++ APR_BUCKET_REMOVE(b); ++ apr_bucket_destroy(b); ++ } + b = next; + } + } diff --git a/apache2.changes b/apache2.changes index f581c2d..dafe375 100644 --- a/apache2.changes +++ b/apache2.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed 27 Feb 2019 01:59:17 PM UTC - pgajdos@suse.com + +- added patches + fix https://github.com/icing/mod_h2/issues/167 [bsc#1125965] + + apache2-mod_http2-issue-167.patch + ------------------------------------------------------------------- Fri Feb 8 01:58:37 UTC 2019 - Jan Engelhardt diff --git a/apache2.spec b/apache2.spec index 78d6bb2..f7cf0af 100644 --- a/apache2.spec +++ b/apache2.spec @@ -145,6 +145,8 @@ Patch111: httpd-visibility.patch # PATCH-FEATURE-UPSTREAM kstreitova@suse.com -- backport of HttpContentLengthHeadZero and HttpExpectStrict Patch115: httpd-2.4.x-fate317766-config-control-two-protocol-options.diff Patch116: deprecated-scripts-arch.patch +# fix https://github.com/icing/mod_h2/issues/167 [bsc#1125965] +Patch117: apache2-mod_http2-issue-167.patch BuildRequires: apache-rpm-macros-control BuildRequires: apr-util-devel #Since 2.4.7 the event MPM requires apr 1.5.0 or later. @@ -334,6 +336,7 @@ to administrators of web servers in general. %if 0%{?suse_version} == 1110 %patch116 -p1 %endif +%patch117 -p1 cat %{_sourcedir}/SUSE-NOTICE >> NOTICE # install READMEs a=$(basename %{SOURCE22})