diff options
author | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2021-12-10 22:05:20 +0100 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2021-12-16 02:37:26 +0100 |
commit | cee04cbfe1bf77db5a5bb4ade786573f08a586fc (patch) | |
tree | 435d69f3c57c3f76fc0ec206d0dd6956df5a7b03 /libavcodec/dxva2_vp9.c | |
parent | d59f454ed2ba4cc89533a84d727eef9aaaed635d (diff) | |
download | ffmpeg-cee04cbfe1bf77db5a5bb4ade786573f08a586fc.tar.gz |
avcodec/decode: Fix leaks upon subtitle decoding errors
Up until now, various subtitle decoders have not cleaned up
the AVSubtitle on error; this task must not be left to the user
because the documentation explicitly states that the AVSubtitle
"must be freed with avsubtitle_free if *got_sub_ptr is set"
(which it isn't on error).
Leaks happen upon failure in ff_ass_add_rect() or in
ass_decode_frame(); freeing generically also allows to remove
now redundant freeing code in pgssubdec and dvbsubdec.
While just at it, also reset got_sub_ptr generically on error.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavcodec/dxva2_vp9.c')
0 files changed, 0 insertions, 0 deletions