Skip to content

Commit 0052be6

Browse files
committed
Make HTTP server stack size configurable
1 parent c603513 commit 0052be6

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/sensesp/net/http_server.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@
1313
#include "sensesp/system/configurable.h"
1414
#include "sensesp_base_app.h"
1515

16+
#ifndef HTTP_SERVER_STACK_SIZE
17+
#define HTTP_SERVER_STACK_SIZE 8192
18+
#endif
19+
1620
namespace sensesp {
1721

1822
#ifndef HTTP_DEFAULT_PORT
@@ -60,7 +64,7 @@ class HTTPServer : public Configurable {
6064
: config_(HTTPD_DEFAULT_CONFIG()),
6165
Configurable(config_path) {
6266
config_.server_port = port;
63-
config_.stack_size = 4096;
67+
config_.stack_size = HTTP_SERVER_STACK_SIZE;
6468
config_.max_uri_handlers = 20;
6569
config_.uri_match_fn = httpd_uri_match_wildcard;
6670
String auth_realm_ = "Login required for " + SensESPBaseApp::get_hostname();

0 commit comments

Comments
 (0)