summaryrefslogtreecommitdiff
path: root/libavcodec/png_parser.c
diff options
context:
space:
mode:
authorThierry Foucu <tfoucu@gmail.com>2020-06-04 13:03:00 -0700
committerMichael Niedermayer <michael@niedermayer.cc>2020-06-06 00:25:00 +0200
commitd5422a14e2a84e4feb7124c7e4d1950fdae697aa (patch)
tree9dd1b701ecc2ed5d6c89c2c9fd9730d19efa784c /libavcodec/png_parser.c
parentcf28521fee22dbe2f7eeb8ab0306c0fd0802c48a (diff)
downloadffmpeg-d5422a14e2a84e4feb7124c7e4d1950fdae697aa.tar.gz
libavcodec/png_parser.c: fix a use_of_uninitialized_value in target_dec_fuzzer.
the target_dec_fuzzer is checking for the avpkt.data pointer but if the png parser cannot combine the frame, the poutbuf is not set. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/png_parser.c')
-rw-r--r--libavcodec/png_parser.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavcodec/png_parser.c b/libavcodec/png_parser.c
index 74f2964118..9ec8551a1b 100644
--- a/libavcodec/png_parser.c
+++ b/libavcodec/png_parser.c
@@ -45,6 +45,7 @@ static int png_parse(AVCodecParserContext *s, AVCodecContext *avctx,
s->pict_type = AV_PICTURE_TYPE_NONE;
*poutbuf_size = 0;
+ *poutbuf = NULL;
if (!ppc->pc.frame_start_found) {
uint64_t state64 = ppc->pc.state64;