Message ID | 1507536007-26802-2-git-send-email-odpbot@yandex.ru |
---|---|
State | New |
Headers | show |
Series | [API-NEXT,v3,1/2] linux-gen: chksum: correct uninitialized variable bug | expand |
diff --git a/platform/linux-generic/odp_chksum.c b/platform/linux-generic/odp_chksum.c index 349bdaf46..a792971ef 100644 --- a/platform/linux-generic/odp_chksum.c +++ b/platform/linux-generic/odp_chksum.c @@ -22,7 +22,7 @@ uint16_t odp_chksum_ones_comp16(const void *p, uint32_t len) /* Add left-over byte, if any */ if (len > 0) { - uint16_t left_over; + uint16_t left_over = 0; *(uint8_t *)&left_over = *(const uint8_t *)data; sum += left_over;