mirror of
https://github.com/cesanta/mongoose.git
synced 2026-12-05 22:08:23 +00:00
Remove MG_ENABLE_STDIO and cleanup
This commit is contained in:
1 parent
d130c6f42d
commit
2a2c17a232
15 files changed
+59
-89
No files matched your search
@@ -10,12 +10,7 @@ static const char *s_listening_address = "http://0.0.0.0:80";
|
||||
// Event handler for the listening connection.
|
||||
static void cb(struct mg_connection *c, int ev, void *ev_data, void *fn_data) {
|
||||
if (ev == MG_EV_HTTP_MSG) {
|
||||
#if MG_ENABLE_STDIO
|
||||
struct mg_http_serve_opts opts = {.root_dir = "/"};
|
||||
mg_http_serve_dir(c, ev_data, &opts);
|
||||
#else
|
||||
mg_http_reply(c, 200, "", "hello, %s!\n", "world");
|
||||
#endif
|
||||
}
|
||||
(void) fn_data;
|
||||
(void) ev_data;
|
||||
|
||||
Reference in new issue
Block a user