From b95041ee2ccc804752f103520f26fcce9c651465 Mon Sep 17 00:00:00 2001 From: Alois Klingler Date: Mon, 20 Nov 2023 06:59:23 +0100 Subject: [PATCH] init variable on starting --- include/ModbusDtu.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/ModbusDtu.h b/include/ModbusDtu.h index e0c450136..cdcbd9cd3 100644 --- a/include/ModbusDtu.h +++ b/include/ModbusDtu.h @@ -11,7 +11,7 @@ class ModbusDtuClass { void loop(); private: - uint32_t _lastPublish; + uint32_t _lastPublish = 0; bool _isstarted = false; };