mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-25 19:56:30 +00:00
Fix bad define ESP82666
This commit is contained in:
parent
0dfab3684c
commit
a30f47a901
@ -9906,7 +9906,7 @@ void Script_Handle_Hue(String path) {
|
|||||||
|
|
||||||
uint16_t args = Webserver->args();
|
uint16_t args = Webserver->args();
|
||||||
|
|
||||||
#ifdef ESP82666
|
#ifdef ESP8266
|
||||||
char *json = (char*)Webserver->arg(args - 1).c_str();
|
char *json = (char*)Webserver->arg(args - 1).c_str();
|
||||||
#else
|
#else
|
||||||
String request_arg = Webserver->arg(args - 1);
|
String request_arg = Webserver->arg(args - 1);
|
||||||
|
@ -763,7 +763,7 @@ void HueLightsCommand(uint8_t device, uint32_t device_id, String &response) {
|
|||||||
if (Webserver->args()) {
|
if (Webserver->args()) {
|
||||||
response = "[";
|
response = "[";
|
||||||
|
|
||||||
#ifdef ESP82666 // ESP8266 memory is limited, avoid copying and modify in place
|
#ifdef ESP8266 // ESP8266 memory is limited, avoid copying and modify in place
|
||||||
JsonParser parser((char*) Webserver->arg((Webserver->args())-1).c_str());
|
JsonParser parser((char*) Webserver->arg((Webserver->args())-1).c_str());
|
||||||
#else // does not work on ESP32, we need to get a fresh copy of the string
|
#else // does not work on ESP32, we need to get a fresh copy of the string
|
||||||
String request_arg = Webserver->arg((Webserver->args())-1);
|
String request_arg = Webserver->arg((Webserver->args())-1);
|
||||||
|
@ -270,9 +270,9 @@ int32_t ZigbeeHandleHue(uint16_t shortaddr, uint8_t ep, uint32_t device_id, uint
|
|||||||
if (Webserver->args()) {
|
if (Webserver->args()) {
|
||||||
response = "[";
|
response = "[";
|
||||||
|
|
||||||
#ifdef ESP82666 // ESP8266 memory is limited, avoid copying and modify in place
|
#ifdef ESP8266 // ESP8266 memory is limited, avoid copying and modify in place
|
||||||
JsonParser parser((char*) Webserver->arg((Webserver->args())-1).c_str());
|
JsonParser parser((char*) Webserver->arg((Webserver->args())-1).c_str());
|
||||||
#else // does not work on ESP32, we need to get a fresh copy of the string
|
#else // does not work on ESP32, we need to get a fresh copy of the string
|
||||||
String request_arg = Webserver->arg((Webserver->args())-1);
|
String request_arg = Webserver->arg((Webserver->args())-1);
|
||||||
JsonParser parser((char*) request_arg.c_str());
|
JsonParser parser((char*) request_arg.c_str());
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user