Commit 1b5d3359 authored by Janne Grunau's avatar Janne Grunau

parsing: error out when trying to decode a frame without tile data

Replaces an assert with a check and return error. Fixes an assert fail
with crash-ea35702b18cd8c17da7505126eb0e6aa6914f09d.
parent a32c5086
......@@ -1065,7 +1065,8 @@ int dav1d_parse_obus(Dav1dContext *const c, Dav1dData *const in) {
if (c->have_seq_hdr && c->have_frame_hdr &&
c->tile_mask == (1 << n_tiles) - 1)
{
assert(c->n_tile_data);
if (!c->n_tile_data)
return -EINVAL;
dav1d_submit_frame(c);
assert(!c->n_tile_data);
c->have_frame_hdr = 0;
......
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