We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7f2106e commit 66fd711Copy full SHA for 66fd711
2 files changed
Common++/src/OUILookup.cpp
@@ -92,7 +92,7 @@ namespace pcpp
92
}
93
94
// Get MAC address
95
- uint8_t buffArray[6];
+ uint8_t buffArray[6] = { 0 };
96
addr.copyTo(buffArray);
97
98
const uint64_t macAddr = (((uint64_t)((buffArray)[5]) << 0) + ((uint64_t)((buffArray)[4]) << 8) +
Packet++/src/StpLayer.cpp
@@ -20,7 +20,7 @@ namespace pcpp
20
21
uint64_t StpLayer::macAddressToID(const pcpp::MacAddress& addr)
22
{
23
- uint8_t value[6];
+ uint8_t value[6] = { 0 };
24
addr.copyTo(value);
25
return ((uint64_t(value[0]) << 40) | (uint64_t(value[1]) << 32) | (uint64_t(value[2]) << 24) |
26
(uint64_t(value[3]) << 16) | (uint64_t(value[4]) << 8) | (uint64_t(value[5])));
0 commit comments