1
0
mirror of https://github.com/peterantypas/maiana.git synced 2025-06-01 07:10:33 -07:00

Memory overflow bug

This commit is contained in:
Peter Antypas 2020-10-08 15:08:18 -07:00
parent aeb42d15ec
commit cefd3a2111

View File

@ -32,14 +32,14 @@ void TXPacket::configure(VHFChannel channel)
{ {
mTestPacket = false; mTestPacket = false;
mChannel = channel; mChannel = channel;
strcpy(mMessageType, "<unknown>"); memset(mMessageType, 0, sizeof mMessageType);
} }
void TXPacket::configureForTesting(VHFChannel channel, uint16_t numBits) void TXPacket::configureForTesting(VHFChannel channel, uint16_t numBits)
{ {
mTestPacket = true; mTestPacket = true;
mChannel = channel; mChannel = channel;
strcpy(mMessageType, "<unknown>"); strcpy(mMessageType, "00");
mSize = numBits; mSize = numBits;
} }