From eb78f134f3cae9f4f7a284f93689224d90c10978 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=BCbbe=20Onken?= Date: Fri, 29 Sep 2023 20:30:09 +0200 Subject: [PATCH] Fix unused/uninitialized variable warnings (#214) --- src/Astronomy.cpp | 2 +- src/MetOfficeClient.cpp | 1 - src/ThingspeakClient.cpp | 1 - src/WorldClockClient.cpp | 1 - 4 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/Astronomy.cpp b/src/Astronomy.cpp index 0eed7ee..361292c 100644 --- a/src/Astronomy.cpp +++ b/src/Astronomy.cpp @@ -111,7 +111,7 @@ Astronomy::MoonData Astronomy::calculateMoonData(uint16_t year, uint8_t month, u } else month -= 2; c = year / 100; - jd += 30.59 * month; + jd = 30.59 * month; jd += 365.25 * year; jd += day; jd += c / 4 - c; diff --git a/src/MetOfficeClient.cpp b/src/MetOfficeClient.cpp index 42fe7fb..6d23305 100644 --- a/src/MetOfficeClient.cpp +++ b/src/MetOfficeClient.cpp @@ -92,7 +92,6 @@ void MetOfficeClient::doUpdate(String url) { } } - int pos = 0; boolean isBody = false; char c; diff --git a/src/ThingspeakClient.cpp b/src/ThingspeakClient.cpp index d4d7141..963acee 100644 --- a/src/ThingspeakClient.cpp +++ b/src/ThingspeakClient.cpp @@ -38,7 +38,6 @@ void ThingspeakClient::getLastChannelItem(String channelId, String readApiKey) { } } - int pos = 0; boolean isBody = false; char c; diff --git a/src/WorldClockClient.cpp b/src/WorldClockClient.cpp index adc7cf6..ef7408e 100644 --- a/src/WorldClockClient.cpp +++ b/src/WorldClockClient.cpp @@ -87,7 +87,6 @@ void WorldClockClient::updateTime() { } } - int pos = 0; boolean isBody = false; char c; client.setNoDelay(false);