1
0
mirror of https://github.com/craigerl/aprsd.git synced 2026-06-07 08:34:40 -04:00

Fixed issue with packet object and prepare()

If any part of the code had a packet object and called prepare()
on it, it would create a msgNo if it wasn't set.  Sometimes we
get packets on the wire/RF that don't have a msgNo, so adding one
locally is wrong.   We should ONLY create a msgNo on a packet that
is destined for transmission.

This patch ensures that even if prepare() is called, that only
packets that are created locally for TX get a msgNo unless it
already exists from RX'd packets.
This commit is contained in:
2024-11-26 16:52:39 -05:00
parent 3a8b8f26dd
commit f66b96288f
4 changed files with 21 additions and 10 deletions
+1 -1
View File
@@ -61,7 +61,7 @@ class TestAPRSISClient(unittest.TestCase):
"connected": True,
"filter": "m/50",
"login_status": {"message": mock.ANY, "success": True},
"server_keepalive": mock_client.aprsd_keepalive,
"connection_keepalive": mock_client.aprsd_keepalive,
"server_string": mock_client.server_string,
"transport": "aprsis",
},