Replace memset() in PJONDefines.h to avoid build warning (#1527) (#1528)

This commit is contained in:
Virtual Maker
2022-07-06 21:12:45 +02:00
committed by GitHub
parent 423b9d790a
commit 3f37f8d91a

View File

@@ -412,8 +412,9 @@ struct PJONTools {
static void parse_header(const uint8_t *packet, PJON_Packet_Info &info)
{
memset(&info, 0, sizeof info);
uint8_t index = 0;
info = PJON_Packet_Info{};
info.rx.id = packet[index++];
bool extended_length = packet[index] & PJON_EXT_LEN_BIT;
info.header = packet[index++];