mmdvm-flake/MMDVMHost/0003-fix-null-controller.patch

23 lines
563 B
Diff
Raw Permalink Normal View History

2024-11-05 21:30:44 +01:00
diff --git a/NullController.cpp b/NullController.cpp
index edfeffe..598b783 100644
--- a/NullController.cpp
+++ b/NullController.cpp
@@ -20,6 +20,7 @@
#include <cstdio>
#include <cassert>
+#include <cstdint>
const unsigned char MMDVM_FRAME_START = 0xE0U;
@@ -120,7 +121,8 @@ void CNullController::writeVersion()
::memset(reply + 7U, 0x00U, 16U);
uint8_t count = 23U;
- for (uint8_t i = 0U; HARDWARE[i] != 0x00U; i++, count++)
+ uint8_t i = 0;
+ for (i = 0U; HARDWARE[i] != 0x00U; i++, count++)
reply[count] = HARDWARE[i];
reply[1U] = count;