ref: 41cd4199f149760a4d16326342d646b2eb66e8b0
parent: 4687c4696f780207bbb7f8d14038302f0e9c63bd
author: Ronald S. Bultje <[email protected]>
date: Wed Apr 1 15:34:16 EDT 2020
Skip loop restoration cache buffer resize for too-small buffers Fixes crashes in dav1d_resize_{avx2,ssse3} on very small resolutions with super_res enabled but skipped because the width is too small.
--- a/src/lr_apply_tmpl.c
+++ b/src/lr_apply_tmpl.c
@@ -73,7 +73,7 @@
dst += 4 * PXSTRIDE(dst_stride);
src += (stripe_h - 2) * PXSTRIDE(src_stride);
- if (f->frame_hdr->super_res.enabled) {
+ if (f->frame_hdr->width[0] != f->frame_hdr->width[1]) {
while (row + stripe_h <= row_h) {
const int n_lines = 4 - (row + stripe_h + 1 == h);
f->dsp->mc.resize(dst, dst_stride, src, src_stride,