From f0e57e92b4c8adc7cb8b53f7f34bf0544065050f Mon Sep 17 00:00:00 2001 From: fvanroie <15969459+fvanroie@users.noreply.github.com> Date: Sat, 7 Aug 2021 01:39:52 +0200 Subject: [PATCH] Don't use http src on ESP8266 --- src/hasp/hasp_attribute.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/hasp/hasp_attribute.cpp b/src/hasp/hasp_attribute.cpp index 8f786a69..ebfb07b5 100644 --- a/src/hasp/hasp_attribute.cpp +++ b/src/hasp/hasp_attribute.cpp @@ -11,6 +11,8 @@ /*** Image Improvement ***/ #if defined(ARDUINO_ARCH_ESP8266) #include +#define lodepng_malloc malloc +#define lodepng_free free #endif #if defined(ARDUINO_ARCH_ESP32) @@ -1007,7 +1009,7 @@ static hasp_attribute_type_t special_attribute_src(lv_obj_t* obj, const char* pa if(payload != strstr_P(payload, PSTR("http://"))) { lv_img_set_src(obj, payload); } else { -#ifdef ARDUINO +#if defined(ARDUINO) && defined(ARDUINO_ARCH_ESP32) HTTPClient http; http.begin(payload); int httpCode = http.GET();