fix networking stack crash

This commit is contained in:
Siwat Sirichai 2024-10-10 19:07:23 +07:00
parent d276e6d255
commit 5bce34bc5e
2 changed files with 2 additions and 2 deletions

View File

@ -1,3 +1,3 @@
#pragma once
#define SDK_VESRION "2.9.6"
#define SDK_VESRION "2.9.7"

View File

@ -633,7 +633,7 @@ void ESPMegaIoT::loadNetworkConfig()
// subnet: 255.255.255.0
// dns1: 1.1.1.1
// dns2: 9.9.9.9
if (network_config.ip == 0 && network_config.gateway == 0 && network_config.subnet == 0 && network_config.dns1 == 0 && network_config.dns2 == 0)
if ((uint32_t)network_config.ip == 0 && (uint32_t)network_config.gateway == 0 && (uint32_t)network_config.subnet == 0 && (uint32_t)network_config.dns1 == 0 && (uint32_t)network_config.dns2 == 0)
{
network_config.ip = IPAddress(192, 168, 0, 99);
network_config.gateway = IPAddress(192, 168, 0, 1);