mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-20 11:19:56 +00:00
Remove MG_ENABLE_DIRLIST, add mg_http_serve_opts :: enable_dir_listing
This commit is contained in:
1 parent
789372c5b3
commit
a419e16f26
12 files changed
+47
-83
No files matched your search
@@ -48,8 +48,9 @@ static void http_ev_handler(struct mg_connection *c, int ev, void *ev_data) {
|
||||
} else if (mg_match(hm->uri, mg_str("/files/#"), NULL)) {
|
||||
struct mg_http_serve_opts opts = {
|
||||
.root_dir = "/files/=/fs/",
|
||||
.allow_delete = true,
|
||||
.allow_upload = true,
|
||||
.enable_delete = true,
|
||||
.enable_upload = true,
|
||||
.enable_dir_listing = true,
|
||||
};
|
||||
mg_http_serve_dir(c, hm, &opts);
|
||||
} else {
|
||||
|
||||
Reference in new issue
Block a user