From f8c186b8a9bfbefef284f0e8092c721238b46a6d Mon Sep 17 00:00:00 2001 From: "Dirk O. Kaar" Date: Thu, 28 Nov 2019 14:43:50 +0100 Subject: [PATCH 1/2] Conflict with pre-included Arduino.h (the indirect includes thereof) resolved. --- cores/esp8266/sntp-lwip2.cpp | 24 +----------------------- 1 file changed, 1 insertion(+), 23 deletions(-) diff --git a/cores/esp8266/sntp-lwip2.cpp b/cores/esp8266/sntp-lwip2.cpp index 063cc5be2b..6b85279542 100644 --- a/cores/esp8266/sntp-lwip2.cpp +++ b/cores/esp8266/sntp-lwip2.cpp @@ -38,7 +38,7 @@ */ #include -#include +#include #include #include #include "coredecls.h" @@ -133,30 +133,8 @@ static const int year_lengths[2] = { 365, 366 } ; -struct tm -{ - int tm_sec; - int tm_min; - int tm_hour; - int tm_mday; - int tm_mon; - int tm_year; - int tm_wday; - int tm_yday; - int tm_isdst; -}; struct tm res_buf; -typedef struct __tzrule_struct -{ - char ch; - int m; - int n; - int d; - int s; - time_t change; - int offset; -} __tzrule_type; __tzrule_type sntp__tzrule[2]; struct tm * From 4fa20f04b49fb31ed8f7655a6217c5b7551ddbf0 Mon Sep 17 00:00:00 2001 From: "Dirk O. Kaar" Date: Thu, 28 Nov 2019 18:15:08 +0100 Subject: [PATCH 2/2] Include both time.h and sys/time.h --- cores/esp8266/sntp-lwip2.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/cores/esp8266/sntp-lwip2.cpp b/cores/esp8266/sntp-lwip2.cpp index 6b85279542..b046a1990c 100644 --- a/cores/esp8266/sntp-lwip2.cpp +++ b/cores/esp8266/sntp-lwip2.cpp @@ -39,6 +39,7 @@ #include #include +#include #include #include #include "coredecls.h"