mirror of
https://github.com/cesanta/mongoose.git
synced 2026-12-04 21:58:22 +00:00
Fix C++ build
This commit is contained in:
1 parent
31568de0fb
commit
f123bf3154
2 files changed
+4
-2
No files matched your search
+2
-1
@@ -3342,7 +3342,8 @@ static inline void mg_dash_ev_handler(struct mg_connection *c, int ev,
|
|||||||
if (mg_match(hm->uri, mg_str("/api/websocket"), NULL)) {
|
if (mg_match(hm->uri, mg_str("/api/websocket"), NULL)) {
|
||||||
mg_ws_upgrade(c, hm, NULL);
|
mg_ws_upgrade(c, hm, NULL);
|
||||||
} else {
|
} else {
|
||||||
struct mg_http_serve_opts opts = {0};
|
struct mg_http_serve_opts opts;
|
||||||
|
memset(&opts, 0, sizeof(opts));
|
||||||
opts.fs = &mg_fs_packed;
|
opts.fs = &mg_fs_packed;
|
||||||
mg_mem_files = mg_packed_files;
|
mg_mem_files = mg_packed_files;
|
||||||
mg_http_serve_file(c, hm, "/dashboard.html", &opts);
|
mg_http_serve_file(c, hm, "/dashboard.html", &opts);
|
||||||
|
|||||||
+2
-1
@@ -204,7 +204,8 @@ static inline void mg_dash_ev_handler(struct mg_connection *c, int ev,
|
|||||||
if (mg_match(hm->uri, mg_str("/api/websocket"), NULL)) {
|
if (mg_match(hm->uri, mg_str("/api/websocket"), NULL)) {
|
||||||
mg_ws_upgrade(c, hm, NULL);
|
mg_ws_upgrade(c, hm, NULL);
|
||||||
} else {
|
} else {
|
||||||
struct mg_http_serve_opts opts = {0};
|
struct mg_http_serve_opts opts;
|
||||||
|
memset(&opts, 0, sizeof(opts));
|
||||||
opts.fs = &mg_fs_packed;
|
opts.fs = &mg_fs_packed;
|
||||||
mg_mem_files = mg_packed_files;
|
mg_mem_files = mg_packed_files;
|
||||||
mg_http_serve_file(c, hm, "/dashboard.html", &opts);
|
mg_http_serve_file(c, hm, "/dashboard.html", &opts);
|
||||||
|
|||||||
Reference in new issue
Block a user