]> granicus.if.org Git - apache/commitdiff
explicitly setting connection state on end of processing to help reclaim resources
authorStefan Eissing <icing@apache.org>
Mon, 31 Aug 2015 16:12:11 +0000 (16:12 +0000)
committerStefan Eissing <icing@apache.org>
Mon, 31 Aug 2015 16:12:11 +0000 (16:12 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1700271 13f79535-47bb-0310-9956-ffa450edef68

modules/http2/h2_conn.c

index 1d644e4050a2049731f3f8486a8781a10d7bebf1..d83db748a9ada3524cf6b7b339805016ac836e7b 100644 (file)
@@ -161,6 +161,7 @@ apr_status_t h2_conn_main(conn_rec *c)
 {
     h2_config *config = h2_config_get(c);
     h2_session *session;
+    apr_status_t status;
     
     ap_log_cerror(APLOG_MARK, APLOG_DEBUG, 0, c, "h2_conn_main start");
     if (!workers) {
@@ -174,7 +175,12 @@ apr_status_t h2_conn_main(conn_rec *c)
         return APR_EGENERAL;
     }
     
-    return h2_session_process(session);
+    status = h2_session_process(session);
+
+    /* Make sure this connection gets cleaned up properly. */
+    c->cs->state = CONN_STATE_LINGER;
+
+    return status;
 }
 
 apr_status_t h2_session_process(h2_session *session)