History

avcodec/cfhdenc: Allocate more space

Fixes: Assertion failure Fixes: 68979/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CFHD_fuzzer-5375874714107904

Michael Niedermayer committed 2 years ago

Commit a308d791 parent 6420c1b1 file · +1 −2Browse files

Showing the changes to libavcodec (1 of 1 file). Show all

Unified · Split

libavcodec/cfhdenc.c+1−2
@@ -552,7 +552,7 @@ static int cfhd_encode_frame(AVCodecContext *avctx, AVPacket *pkt, · 551 unmodified lines
552552 width, height * 2);
553553 }
554554
555− ret = ff_alloc_packet(avctx, pkt, 256LL + s->planes * (2LL * avctx->width * (avctx->height + 15) + 2048LL));
555+ ret = ff_alloc_packet(avctx, pkt, 256LL + s->planes * (4LL * avctx->width * (avctx->height + 15) + 2048LL));
556556 if (ret < 0)
557557 return ret;
558558
@@ -760,7 +760,6 @@ static int cfhd_encode_frame(AVCodecContext *avctx, AVPacket *pkt, · 201 unmodified lines
760760 } else if (count > 0) {
761761 count = put_runcode(pb, count, rb);
762762 }
763−
764763 put_bits(pb, cb[index].size, cb[index].bits);
765764 }
766765

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t