Skip to content

Commit 3f37f8d

Browse files
Replace memset() in PJONDefines.h to avoid build warning (#1527) (#1528)
1 parent 423b9d7 commit 3f37f8d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

hal/transport/PJON/driver/PJONDefines.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,8 +412,9 @@ struct PJONTools {
412412

413413
static void parse_header(const uint8_t *packet, PJON_Packet_Info &info)
414414
{
415-
memset(&info, 0, sizeof info);
416415
uint8_t index = 0;
416+
info = PJON_Packet_Info{};
417+
417418
info.rx.id = packet[index++];
418419
bool extended_length = packet[index] & PJON_EXT_LEN_BIT;
419420
info.header = packet[index++];

0 commit comments

Comments
 (0)