From 1e32c94e81a941307820f0db45c8a74358185467 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Tue, 28 Apr 2026 10:43:24 -0500 Subject: [PATCH] Simplify comments in secondsToMsClamped function Removed detailed comments about seconds to milliseconds conversion. --- src/mesh/Default.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/mesh/Default.cpp b/src/mesh/Default.cpp index 7f3d6c6e9..7a2d9e410 100644 --- a/src/mesh/Default.cpp +++ b/src/mesh/Default.cpp @@ -2,11 +2,7 @@ #include "meshUtils.h" -// Convert seconds to ms, clamping at INT32_MAX (~24.86 days). Callers store the -// result in uint32_t but the ultimate consumers (OSThread runOnce returns, -// `MAX_INTERVAL`, Apple-client interop per the FIXME at Default.h:14) treat it -// as int32_t. Saturating at INT32_MAX keeps every conversion well-defined and -// non-negative; no realistic interval (broadcast, throttle, sleep) needs more. +// Convert seconds to ms, clamping at INT32_MAX (~24.86 days) static inline uint32_t secondsToMsClamped(uint32_t secs) { constexpr uint32_t MAX_MS = static_cast(INT32_MAX); @@ -80,4 +76,4 @@ uint8_t Default::getConfiguredOrDefaultHopLimit(uint8_t configured) #else return (configured >= HOP_MAX) ? HOP_MAX : config.lora.hop_limit; #endif -} \ No newline at end of file +}