mirror of
https://github.com/jorisvink/kore
synced 2025-03-09 04:29:02 -04:00
simplify logic
This commit is contained in:
parent
04deeeafb9
commit
04f4306cf2
@ -179,9 +179,7 @@ filemap_serve(struct http_request *req, struct filemap_entry *map)
|
||||
lookup:
|
||||
if (realpath(fpath, rpath) == NULL) {
|
||||
if (errno == ENOENT) {
|
||||
if (index || kore_filemap_ext == NULL) {
|
||||
req->status = HTTP_STATUS_NOT_FOUND;
|
||||
} else {
|
||||
if (index == 0 && kore_filemap_ext != NULL) {
|
||||
len = snprintf(fpath, sizeof(fpath),
|
||||
"%s/%s%s", map->ondisk, path,
|
||||
kore_filemap_ext);
|
||||
|
Loading…
x
Reference in New Issue
Block a user