potential fix for Range Test Leak. Poking around in the dark.

This commit is contained in:
Thomas Göttgens
2023-02-03 00:42:35 +01:00
parent 46fa08dc33
commit fab5e4c5cc
2 changed files with 2 additions and 17 deletions

View File

@@ -56,7 +56,7 @@ int32_t RangeTestModule::runOnce()
return (5000); // Sending first message 5 seconds after initilization.
} else {
LOG_INFO("Initializing Range Test Module -- Receiver\n");
return (INT32_MAX);
return disable();
// This thread does not need to run as a receiver
}
@@ -91,17 +91,9 @@ int32_t RangeTestModule::runOnce()
return disable();
}
meshtastic_MeshPacket *RangeTestModuleRadio::allocReply()
{
auto reply = allocDataPacket(); // Allocate a packet for sending
return reply;
}
void RangeTestModuleRadio::sendPayload(NodeNum dest, bool wantReplies)
{
meshtastic_MeshPacket *p = allocReply();
meshtastic_MeshPacket *p = allocDataPacket();
p->to = dest;
p->decoded.want_response = wantReplies;