mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-12-25 18:14:53 +00:00
httpd: fix bug #58223
This commit is contained in:
parent
1678b21a94
commit
fdd702e61b
@ -874,11 +874,11 @@ get_http_headers(struct http_state *hs, const char *uri)
|
||||
special case. We assume that any filename with "404" in it must be
|
||||
indicative of a 404 server error whereas all other files require
|
||||
the 200 OK header. */
|
||||
if (strstr(uri, "404.") == uri) {
|
||||
if (strstr(uri, "/404.") == uri) {
|
||||
hs->hdrs[HDR_STRINGS_IDX_HTTP_STATUS] = g_psHTTPHeaderStrings[HTTP_HDR_NOT_FOUND];
|
||||
} else if (strstr(uri, "400.") == uri) {
|
||||
} else if (strstr(uri, "/400.") == uri) {
|
||||
hs->hdrs[HDR_STRINGS_IDX_HTTP_STATUS] = g_psHTTPHeaderStrings[HTTP_HDR_BAD_REQUEST];
|
||||
} else if (strstr(uri, "501.") == uri) {
|
||||
} else if (strstr(uri, "/501.") == uri) {
|
||||
hs->hdrs[HDR_STRINGS_IDX_HTTP_STATUS] = g_psHTTPHeaderStrings[HTTP_HDR_NOT_IMPL];
|
||||
} else {
|
||||
hs->hdrs[HDR_STRINGS_IDX_HTTP_STATUS] = g_psHTTPHeaderStrings[HTTP_HDR_OK];
|
||||
|
Loading…
Reference in New Issue
Block a user