fix segfault in log_error_write if host is empty
git-svn-id: svn+ssh://svn.lighttpd.net/lighttpd/trunk@38 152afb58-edef-0310-8abb-c4023f1b3aa9
parent
d0eac2f218
commit
3e88e04e9a
|
@ -863,8 +863,9 @@ int http_request_parse(server *srv, connection *con) {
|
|||
}
|
||||
}
|
||||
|
||||
/* check hostname field */
|
||||
if (0 != request_check_hostname(srv, con, con->request.http_host)) {
|
||||
/* check hostname field if it is set */
|
||||
if (NULL != con->request.http_host &&
|
||||
0 != request_check_hostname(srv, con, con->request.http_host)) {
|
||||
log_error_write(srv, __FILE__, __LINE__, "sbs",
|
||||
"Invalid Hostname:", con->request.http_host, "-> 400");
|
||||
|
||||
|
|
Loading…
Reference in New Issue