ref: 0665e9b4ae3ae7ed0926a3abd04d49b21ceafa1a
parent: 0af40df746b47057e3f416fbfc49d83e324741b4
author: Hien Ho <[email protected]>
date: Mon Aug 12 11:26:43 EDT 2019
vp8/encoder/bitstream: fix int sanitizer warnings implicit conversion from type 'unsigned int' of value 256 (32-bit, unsigned) to type 'unsigned char' changed the value to 0 (8-bit, unsigned) BUG=webm:1615 Change-Id: I2b630bf22cad28b5a7a8a37f6938e6ebe12bc64e
--- a/vp8/encoder/bitstream.c
+++ b/vp8/encoder/bitstream.c
@@ -171,7 +171,7 @@
validate_buffer(w->buffer + w->pos, 1, w->buffer_end, w->error);
- w->buffer[w->pos++] = (lowvalue >> (24 - offset));
+ w->buffer[w->pos++] = (lowvalue >> (24 - offset)) & 0xff;
lowvalue <<= offset;
shift = count;
lowvalue &= 0xffffff;