You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by ic...@apache.org on 2017/02/01 20:40:38 UTC

svn commit: r1781304 - in /httpd/httpd/trunk: CHANGES modules/http2/h2_stream.c

Author: icing
Date: Wed Feb  1 20:40:38 2017
New Revision: 1781304

URL: http://svn.apache.org/viewvc?rev=1781304&view=rev
Log:
On the trunk:

mod_http2: fix for crash when running out of memory. Initial patch by Robert Swiecki <ro...@swiecki.net>


Modified:
    httpd/httpd/trunk/CHANGES
    httpd/httpd/trunk/modules/http2/h2_stream.c

Modified: httpd/httpd/trunk/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/CHANGES?rev=1781304&r1=1781303&r2=1781304&view=diff
==============================================================================
--- httpd/httpd/trunk/CHANGES [utf-8] (original)
+++ httpd/httpd/trunk/CHANGES [utf-8] Wed Feb  1 20:40:38 2017
@@ -1,6 +1,9 @@
                                                          -*- coding: utf-8 -*-
 Changes with Apache 2.5.0
 
+  *) mod_http2: fix for crash when running out of memory.
+     [Robert Swiecki <ro...@swiecki.net>, Stefan Eissing]
+     
   *) mod_ssl: work around leaks on (graceful) restart. [Yann Ylavic]
 
   *) When using mod_status with the Event MPM, report the number of requests

Modified: httpd/httpd/trunk/modules/http2/h2_stream.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/http2/h2_stream.c?rev=1781304&r1=1781303&r2=1781304&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/http2/h2_stream.c (original)
+++ httpd/httpd/trunk/modules/http2/h2_stream.c Wed Feb  1 20:40:38 2017
@@ -262,11 +262,13 @@ apr_status_t h2_stream_set_request_rec(h
         return APR_ECONNRESET;
     }
     status = h2_request_rcreate(&req, stream->pool, r);
-    ap_log_rerror(APLOG_MARK, APLOG_DEBUG, status, r, APLOGNO(03058)
-                  "h2_request(%d): set_request_rec %s host=%s://%s%s",
-                  stream->id, req->method, req->scheme, req->authority, 
-                  req->path);
-    stream->rtmp = req;
+    if (status == APR_SUCCESS) {
+        ap_log_rerror(APLOG_MARK, APLOG_DEBUG, status, r, APLOGNO(03058)
+                      "h2_request(%d): set_request_rec %s host=%s://%s%s",
+                      stream->id, req->method, req->scheme, req->authority, 
+                      req->path);
+        stream->rtmp = req;
+    }
     return status;
 }