]> granicus.if.org Git - apache/commitdiff
Merge: r1740108, r1740084, r1739932 from trunk
authorStefan Eissing <icing@apache.org>
Wed, 20 Apr 2016 11:14:20 +0000 (11:14 +0000)
committerStefan Eissing <icing@apache.org>
Wed, 20 Apr 2016 11:14:20 +0000 (11:14 +0000)
mod_http2: disabling mmap on file buckets, changing r->protocol to HTTP/2.0

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1740112 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
modules/http2/h2_request.c
modules/http2/h2_session.c
modules/http2/h2_util.c
modules/http2/h2_version.h

diff --git a/CHANGES b/CHANGES
index 459c6b3e3b78f9859f249caf84267d53a3d399b5..61fd6f3c5eb3545e2fc4373fcdb05a801154e623 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -2,7 +2,13 @@
 
 Changes with Apache 2.4.21
 
-
+  *) mod_http2: r->protocol changed to "HTTP/2.0" (was "HTTP/2") as this will
+     give expected syntax in CGI's SERVER_PROTOCOL is more compatible with
+     existing major/minor handling. Fixes PR 59313.
+  
+  *) mod_http2: disabling mmap for file buckets transport due to segmenation
+     faults when files change on the fly.
+     
 Changes with Apache 2.4.20
 
   *) core: Do not read .htaccess if AllowOverride and AllowOverrideList
index 2652661e78ac019e3827798bfb496ebfd7b1dd20..3fd51d47d7144db125ba5efb00766497f1106840 100644 (file)
@@ -436,7 +436,7 @@ request_rec *h2_request_create_rec(const h2_request *req, conn_rec *conn)
     }
 
     ap_parse_uri(r, req->path);
-    r->protocol = "HTTP/2";
+    r->protocol = "HTTP/2.0";
     r->proto_num = HTTP_VERSION(2, 0);
 
     r->the_request = apr_psprintf(r->pool, "%s %s %s", 
index 928bb4a673be6066c11ad490ea11aa3590319513..84a4fe096cf59107887161372e6fd462ad22a136 100644 (file)
@@ -2172,6 +2172,9 @@ apr_status_t h2_session_process(h2_session *session, int async)
                         /* continue reading handling */
                     }
                     else {
+                        ap_log_cerror( APLOG_MARK, APLOG_TRACE1, status, c,
+                                      "h2_session(%ld): idle(1 sec timeout) "
+                                      "read failed", session->id);
                         dispatch_event(session, H2_SESSION_EV_CONN_ERROR, 0, "error");
                     }
                 }
index 06472425f229e9e27e814eb20f4391304d9aba2d..f4e25fda36ef4dad56e0438832e099a18a357a8f 100644 (file)
@@ -454,7 +454,7 @@ apr_status_t h2_util_move(apr_bucket_brigade *to, apr_bucket_brigade *from,
     }
     
     if (!APR_BRIGADE_EMPTY(from)) {
-        apr_bucket *b, *end;
+        apr_bucket *b, *nb, *end;
         
         status = last_not_included(from, maxlen, same_alloc,
                                    pfile_buckets_allowed, &end);
@@ -526,8 +526,11 @@ apr_status_t h2_util_move(apr_bucket_brigade *to, apr_bucket_brigade *from,
                             return status;
                         }
                     }
-                    apr_brigade_insert_file(to, fd, b->start, b->length, 
-                                            to->p);
+                    nb = apr_brigade_insert_file(to, fd, b->start, b->length, 
+                                                 to->p);
+#if APR_HAS_MMAP
+                    apr_bucket_file_enable_mmap(nb, 0);
+#endif
                     --(*pfile_buckets_allowed);
                 }
                 else {
index d68130db71a15d59380f7ce93ffd584aceb5e135..452ccbfc195f4391162e8dfc3118ce0756fa8e1e 100644 (file)
@@ -26,7 +26,7 @@
  * @macro
  * Version number of the http2 module as c string
  */
-#define MOD_HTTP2_VERSION "1.4.6"
+#define MOD_HTTP2_VERSION "1.4.8-DEV"
 
 /**
  * @macro
@@ -34,7 +34,7 @@
  * release. This is a 24 bit number with 8 bits for major number, 8 bits
  * for minor and 8 bits for patch. Version 1.2.3 becomes 0x010203.
  */
-#define MOD_HTTP2_VERSION_NUM 0x010406
+#define MOD_HTTP2_VERSION_NUM 0x010408
 
 
 #endif /* mod_h2_h2_version_h */