mirror of
https://github.com/cesanta/mongoose.git
synced 2026-11-03 13:28:44 +00:00
Merge branch 'master' of github.com:cesanta/mongoose
This commit is contained in:
commit
4e504823c0
3 files changed
+5
-4
No files matched your search
@@ -51,7 +51,7 @@ extern uint32_t SystemCoreClock;
|
|||||||
#define configCPU_CLOCK_HZ (SystemCoreClock)
|
#define configCPU_CLOCK_HZ (SystemCoreClock)
|
||||||
#define configTICK_RATE_HZ ((TickType_t)1000)
|
#define configTICK_RATE_HZ ((TickType_t)1000)
|
||||||
#define configTOTAL_HEAP_SIZE ((size_t)1024 * 128)
|
#define configTOTAL_HEAP_SIZE ((size_t)1024 * 128)
|
||||||
#define configMINIMAL_STACK_SIZE ((uint16_t)128)
|
#define configMINIMAL_STACK_SIZE ((uint16_t)256)
|
||||||
#define configSUPPORT_DYNAMIC_ALLOCATION 1
|
#define configSUPPORT_DYNAMIC_ALLOCATION 1
|
||||||
#define configSUPPORT_STATIC_ALLOCATION 0
|
#define configSUPPORT_STATIC_ALLOCATION 0
|
||||||
|
|
||||||
|
|||||||
@@ -51,7 +51,7 @@
|
|||||||
// <o>Minimal stack size [words] <0-65535>
|
// <o>Minimal stack size [words] <0-65535>
|
||||||
// <i> Stack for idle task and default task stack in words.
|
// <i> Stack for idle task and default task stack in words.
|
||||||
// <i> Default: 128
|
// <i> Default: 128
|
||||||
#define configMINIMAL_STACK_SIZE ((uint16_t)(128))
|
#define configMINIMAL_STACK_SIZE ((uint16_t)(256))
|
||||||
|
|
||||||
// <o>Total heap size [bytes] <0-0xFFFFFFFF>
|
// <o>Total heap size [bytes] <0-0xFFFFFFFF>
|
||||||
// <i> Heap memory size in bytes.
|
// <i> Heap memory size in bytes.
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ struct dhcp {
|
|||||||
unsigned long lease_time_sec;
|
unsigned long lease_time_sec;
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct dhcp s_dhcp = {true, 10, 255, 86400};
|
static struct dhcp s_dhcp = {true, 10, 250, 86400};
|
||||||
|
|
||||||
// Mocked events
|
// Mocked events
|
||||||
static struct event s_events[] = {
|
static struct event s_events[] = {
|
||||||
@@ -185,7 +185,8 @@ static void handle_events_get(struct mg_connection *c) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void handle_dhcp_set(struct mg_connection *c, struct mg_str body) {
|
static void handle_dhcp_set(struct mg_connection *c, struct mg_str body) {
|
||||||
struct dhcp dhcp = {};
|
struct dhcp dhcp;
|
||||||
|
memset(&dhcp, 0, sizeof(dhcp));
|
||||||
mg_json_get_bool(body, "$.enabled", &dhcp.enabled);
|
mg_json_get_bool(body, "$.enabled", &dhcp.enabled);
|
||||||
dhcp.address_begin = mg_json_get_long(body, "$.address_begin", 0);
|
dhcp.address_begin = mg_json_get_long(body, "$.address_begin", 0);
|
||||||
dhcp.address_end = mg_json_get_long(body, "$.address_end", 0);
|
dhcp.address_end = mg_json_get_long(body, "$.address_end", 0);
|
||||||
|
|||||||
Reference in new issue
Block a user