ref: 01cac9f374345c3bba337ef5e63fd2693473bca5
parent: d310bc12b79b5dab04708e5d1ac547b3d921b1f0
parent: 951e60c6fc3802718f30f19c0a302f2c0c62f783
author: James Zern <[email protected]>
date: Thu Jun 27 22:52:20 EDT 2019
Merge "vp9_encodeframe: quiet a few integer sanitizer warnings"
--- a/vp9/encoder/vp9_encodeframe.c
+++ b/vp9/encoder/vp9_encodeframe.c
@@ -4248,13 +4248,21 @@
if (cpi->sf.prune_ref_frame_for_rect_partitions) {
uint8_t used_frames;
used_frames = ref_frames_used[0] | ref_frames_used[1];
- if (used_frames) pc_tree->horizontal[0].skip_ref_frame_mask = ~used_frames;
+ if (used_frames) {
+ pc_tree->horizontal[0].skip_ref_frame_mask = ~used_frames & 0xff;
+ }
used_frames = ref_frames_used[2] | ref_frames_used[3];
- if (used_frames) pc_tree->horizontal[1].skip_ref_frame_mask = ~used_frames;
+ if (used_frames) {
+ pc_tree->horizontal[1].skip_ref_frame_mask = ~used_frames & 0xff;
+ }
used_frames = ref_frames_used[0] | ref_frames_used[2];
- if (used_frames) pc_tree->vertical[0].skip_ref_frame_mask = ~used_frames;
+ if (used_frames) {
+ pc_tree->vertical[0].skip_ref_frame_mask = ~used_frames & 0xff;
+ }
used_frames = ref_frames_used[1] | ref_frames_used[3];
- if (used_frames) pc_tree->vertical[1].skip_ref_frame_mask = ~used_frames;
+ if (used_frames) {
+ pc_tree->vertical[1].skip_ref_frame_mask = ~used_frames & 0xff;
+ }
}
{