Commit 40ef0c7f authored by Yaowu Xu's avatar Yaowu Xu Committed by Yaowu Xu

Promote to 64 bit befoer a large shift

The shift is as large as 49, which does not fit in 32 bit.

Change-Id: Ic84e4eacfde7be386cbff411391366e0559a2824
parent f0e12c27
......@@ -29,7 +29,7 @@ int aom_uleb_decode(const uint8_t *buffer, size_t available, uint64_t *value) {
if (buffer && value) {
for (size_t i = 0; i < kMaximumLeb128Size && i < available; ++i) {
const uint8_t decoded_byte = *(buffer + i) & kLeb128ByteMask;
*value |= decoded_byte << (i * 7);
*value |= ((uint64_t)decoded_byte) << (i * 7);
if ((*(buffer + i) >> 7) == 0) {
status = 0;
break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment