Add unit test to test tile decoding error handling.
Also fix bugs related with corrupted frame handling. Return VPX_CODEC_CORRUPT_FRAME when getting corrupted block. Change-Id: I7207ccc7c68c4df2b40b561315d16e49ccf7ff41
This commit is contained in:
@@ -858,6 +858,7 @@ static const uint8_t *decode_tiles(VP9Decoder *pbi,
|
||||
decode_partition(tile_data->cm, &tile_data->xd, &tile, mi_row, mi_col,
|
||||
&tile_data->bit_reader, BLOCK_64X64);
|
||||
}
|
||||
pbi->mb.corrupted |= tile_data->xd.corrupted;
|
||||
}
|
||||
// Loopfilter one row.
|
||||
if (cm->lf.filter_level) {
|
||||
@@ -1411,6 +1412,9 @@ void vp9_decode_frame(VP9Decoder *pbi,
|
||||
} else {
|
||||
debug_check_frame_counts(cm);
|
||||
}
|
||||
} else {
|
||||
vpx_internal_error(&cm->error, VPX_CODEC_CORRUPT_FRAME,
|
||||
"Decode failed. Frame data is corrupted.");
|
||||
}
|
||||
|
||||
if (cm->refresh_frame_context)
|
||||
|
||||
Reference in New Issue
Block a user