From ea2ac779728f712d1e7deb8e5bebd4b095360d03 Mon Sep 17 00:00:00 2001 From: Tomek Mierzwa <16899265+tmierzwa@users.noreply.github.com> Date: Wed, 21 Oct 2026 10:22:11 +0200 Subject: [PATCH] Fix build with RNS_NEIGHBOR_PROBING=0 Transport::probe_request_handler increments _probes_received unconditionally, but the counter is only declared and defined when RNS_NEIGHBOR_PROBING is enabled, so compiling the feature out fails: Transport.cpp:4307: error: '_probes_received' was not declared in this scope Guard the increment like the counter's declaration, definition, getter and metric. The probe responder itself is unaffected. Co-Authored-By: Claude Opus 5.5 --- src/microReticulum/Transport.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/microReticulum/Transport.cpp b/src/microReticulum/Transport.cpp index 89b5238b..6b976879 100644 --- a/src/microReticulum/Transport.cpp +++ b/src/microReticulum/Transport.cpp @@ -4304,7 +4304,9 @@ static void remote_path_pack_rate_entry(MsgPack::Packer& p, } /*static*/ void Transport::probe_request_handler(const Bytes& data, const Packet& packet) { +#if RNS_NEIGHBOR_PROBING ++_probes_received; +#endif TRACE("Transport::probe_request_handler"); }