https://issues.apache.org/bugzilla/show_bug.cgi?id=53411

--- Comment #4 from Konstantin Kolinko <knst.koli...@gmail.com> ---
Just for reference, confirming what Mark already wrote,
in tc7.0.x/tags/TOMCAT_7_0_27

CharChunk.java line 355
[[[
354     public void append(String s) throws IOException {
355     append(s, 0, s.length());
356     }
]]]

So "s" is null.

Mapper.java line 667
[[[
666     if (host.isNull()) {
667     host.getCharChunk().append(defaultHostName);
668     }
]]]

So "defaultHostName" is null.

The "if(host.isNull())" branch is executed when it is an HTTP/1.0 request that
does not have a "Host" header. Such requests are rare nowadays.


(In reply to comment #2)
> <Engine name="Catalina" defaultHost="localhost">

There must exist <Host name="localhost" > for that. If it does not, the
defaultHost value will be ignored.

MapperListener.java
[[[
        if(found) {
            mapper.setDefaultHostName(defaultHost);
        } else {
            log.warn(sm.getString("mapperListener.unknownDefaultHost",
                    defaultHost, connector));
        }
]]]

-- 
You are receiving this mail because:
You are the assignee for the bug.

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

Reply via email to