From b7b73e83e3d5c78a5fea96a6bcae02e1f0a5c45f Mon Sep 17 00:00:00 2001 From: Andreas Rheinhardt Date: Fri, 26 Mar 2021 18:35:25 +0100 Subject: [PATCH] avcodec/flashsv2enc: Fix undefined NULL + 0 Affected the vsynth*-flashsv2 FATE-tests. Signed-off-by: Andreas Rheinhardt --- libavcodec/flashsv2enc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/flashsv2enc.c b/libavcodec/flashsv2enc.c index 430b6806c8..00aedf0795 100644 --- a/libavcodec/flashsv2enc.c +++ b/libavcodec/flashsv2enc.c @@ -159,7 +159,7 @@ static void init_blocks(FlashSV2Context * s, Block * blocks, b->enc = encbuf; b->data = databuf; encbuf += b->width * b->height * 3; - databuf += !databuf ? 0 : b->width * b->height * 6; + databuf = databuf ? databuf + b->width * b->height * 6 : NULL; } } }