mirror of
https://github.com/meshtastic/firmware.git
synced 2025-04-26 01:52:48 +00:00
Revert "Override RoutingModule's ACK if on wrong channel"
This reverts commit 71c163a8ee
.
This commit is contained in:
parent
0f4261d02f
commit
70bf7c490c
@ -115,11 +115,11 @@ void MeshModule::callPlugins(const MeshPacket &mp, RxSource src)
|
|||||||
// no one should have already replied!
|
// no one should have already replied!
|
||||||
assert(!currentReply);
|
assert(!currentReply);
|
||||||
|
|
||||||
if (mp.decoded.want_response || (isDecoded && mp.want_ack)) {
|
if (mp.decoded.want_response) {
|
||||||
printPacket("Packet on wrong channel, returning error", &mp);
|
printPacket("packet on wrong channel, returning error", &mp);
|
||||||
currentReply = pi.allocErrorResponse(Routing_Error_NOT_AUTHORIZED, &mp);
|
currentReply = pi.allocErrorResponse(Routing_Error_NOT_AUTHORIZED, &mp);
|
||||||
} else
|
} else
|
||||||
printPacket("Packet on wrong channel, but it didn't require a response or ACK", &mp);
|
printPacket("packet on wrong channel, but can't respond", &mp);
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
ProcessMessage handled = pi.handleReceived(mp);
|
ProcessMessage handled = pi.handleReceived(mp);
|
||||||
@ -156,12 +156,12 @@ void MeshModule::callPlugins(const MeshPacket &mp, RxSource src)
|
|||||||
pi.currentRequest = NULL;
|
pi.currentRequest = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((mp.decoded.want_response || mp.want_ack) && toUs) {
|
if (mp.decoded.want_response && toUs) {
|
||||||
if (currentReply) {
|
if (currentReply) {
|
||||||
printPacket("Sending response", currentReply);
|
printPacket("Sending response", currentReply);
|
||||||
service.sendToMesh(currentReply);
|
service.sendToMesh(currentReply);
|
||||||
currentReply = NULL;
|
currentReply = NULL;
|
||||||
} else if(mp.decoded.want_response && mp.from != ourNodeNum) {
|
} else if(mp.from != ourNodeNum) {
|
||||||
// Note: if the message started with the local node we don't want to send a no response reply
|
// Note: if the message started with the local node we don't want to send a no response reply
|
||||||
|
|
||||||
// No one wanted to reply to this requst, tell the requster that happened
|
// No one wanted to reply to this requst, tell the requster that happened
|
||||||
|
Loading…
Reference in New Issue
Block a user