This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch 11.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/11.0.x by this push:
     new d77a9bb502 Create HttpParser earlier
d77a9bb502 is described below

commit d77a9bb50233a1dfcfba5a15a0c6c7e43266251b
Author: remm <r...@apache.org>
AuthorDate: Fri Oct 25 11:55:09 2024 +0200

    Create HttpParser earlier
    
    Some exceptions may be thrown by super.init, which may later be ignored
    depending on the configuration used (controlled by
    Catalina.throwOnInitFailure and its default system property value). If
    things go on and start is ok, the connector could be working and
    accepting requests to a null HttpParser.
---
 java/org/apache/coyote/http11/AbstractHttp11Protocol.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/java/org/apache/coyote/http11/AbstractHttp11Protocol.java 
b/java/org/apache/coyote/http11/AbstractHttp11Protocol.java
index 89301097e0..bb2f36c1a2 100644
--- a/java/org/apache/coyote/http11/AbstractHttp11Protocol.java
+++ b/java/org/apache/coyote/http11/AbstractHttp11Protocol.java
@@ -70,6 +70,8 @@ public abstract class AbstractHttp11Protocol<S> extends 
AbstractProtocol<S> {
 
     @Override
     public void init() throws Exception {
+        httpParser = new HttpParser(relaxedPathChars, relaxedQueryChars);
+
         // Upgrade protocols have to be configured first since the endpoint
         // init (triggered via super.init() below) uses this list to configure
         // the list of ALPN protocols to advertise
@@ -85,8 +87,6 @@ public abstract class AbstractHttp11Protocol<S> extends 
AbstractProtocol<S> {
         for (UpgradeProtocol upgradeProtocol : upgradeProtocols) {
             upgradeProtocol.setHttp11Protocol(this);
         }
-
-        httpParser = new HttpParser(relaxedPathChars, relaxedQueryChars);
     }
 
 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to