diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2012-12-07 01:08:24 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2012-12-07 01:08:24 +0400 |
commit | 759e96164a8d3f0f3f5606ab5f4801859899dd50 (patch) | |
tree | a35135f1f72b9ef401f8d47a3be2aad7a5bb05bd /source/blender/imbuf/intern/IMB_anim.h | |
parent | 77efd71cf8df00cc0fa8f4512c23614fba4fa3ba (diff) |
Fix #33433: Importing video files into movie clip editor crashes Blender
This was a regression in svn rev52718 caused by the fact that we can not
free packet fun until we've finished all manipulation with decoded frame
since frame and packet could share same pointers.
For now restored old behavior of next_packet which seems to be well
tested and better not do bigger refactoring here so close to release.
Memory leak fixed by that revision was fixed by calling av_free_packet
just before avcodec_decode_video2 in cases we're at the end of file.
Tested with valgrind and could not see any memory leaks in ffmpeg
area.
Diffstat (limited to 'source/blender/imbuf/intern/IMB_anim.h')
-rw-r--r-- | source/blender/imbuf/intern/IMB_anim.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/imbuf/intern/IMB_anim.h b/source/blender/imbuf/intern/IMB_anim.h index 684a1476e44..ed349e8f7eb 100644 --- a/source/blender/imbuf/intern/IMB_anim.h +++ b/source/blender/imbuf/intern/IMB_anim.h @@ -178,6 +178,7 @@ struct anim { struct ImBuf *last_frame; int64_t last_pts; int64_t next_pts; + AVPacket next_packet; #endif #ifdef WITH_REDCODE |