Skip to content

Commit 2e0aea2

Browse files
NomDeTomclaude
andcommitted
TrafficManagement: fix cppcheck constVariablePointer warning
`node` in preloadNextHopsFromNodeDB() is never written through — mark it const to satisfy cppcheck's constVariablePointer check in CI. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 0a856ba commit 2e0aea2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/modules/TrafficManagementModule.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -565,7 +565,7 @@ void TrafficManagementModule::preloadNextHopsFromNodeDB()
565565
concurrency::LockGuard guard(&cacheLock);
566566
const size_t count = nodeDB->getNumMeshNodes();
567567
for (size_t i = 0; i < count; i++) {
568-
meshtastic_NodeInfoLite *node = nodeDB->getMeshNodeByIndex(i);
568+
const meshtastic_NodeInfoLite *node = nodeDB->getMeshNodeByIndex(i);
569569
if (!node || node->num == 0 || node->next_hop == 0)
570570
continue;
571571

0 commit comments

Comments
 (0)