AVCodecContext.frame_number is actually only incremented in case encoding was successfull; if e.g. the ff_alloc_packet() below fails, it won't be incremented and therefore it is possible for the previous_frame buffer to be allocated for multiple first frames, leaking every one except the last. So check for whether there already is a previous frame instead. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>pull/388/head
parent
721305e280
commit
a8d39e8846
1 changed files with 1 additions and 1 deletions
Loading…
Reference in new issue