mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2026-01-23 18:10:56 +01:00
avcodec/svq1dec: fix runtime error: applying non-zero offset 4 to null pointer
This commit is contained in:
parent
5d98259841
commit
cb26b85953
1 changed files with 3 additions and 1 deletions
|
|
@ -282,7 +282,7 @@ static int svq1_decode_block_non_intra(GetBitContext *bitbuf, uint8_t *pixels,
|
|||
SVQ1_CALC_CODEBOOK_ENTRIES(ff_svq1_inter_codebooks);
|
||||
|
||||
for (y = 0; y < height; y++) {
|
||||
for (x = 0; x < width / 4; x++, codebook++) {
|
||||
for (x = 0; x < width / 4; x++) {
|
||||
n3 = dst[x];
|
||||
/* add mean value to vector */
|
||||
n1 = n4 + ((n3 & 0xFF00FF00) >> 8);
|
||||
|
|
@ -290,6 +290,8 @@ static int svq1_decode_block_non_intra(GetBitContext *bitbuf, uint8_t *pixels,
|
|||
SVQ1_ADD_CODEBOOK()
|
||||
/* store result */
|
||||
dst[x] = n1 << 8 | n2;
|
||||
if (codebook != NULL)
|
||||
codebook++;
|
||||
}
|
||||
dst += pitch / 4;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue