mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-06 09:39:49 +00:00
Updated comments about freeing format_ctx->pb->buffer.
Signed-off-by: Lukasz Gromanowski <lgromanowski@gmail.com>
This commit is contained in:
parent
1ce4663065
commit
2d4e06cd50
@ -949,7 +949,9 @@ void VideoState::init(const std::string& resourceName)
|
||||
this->format_ctx->pb = ioCtx;
|
||||
|
||||
// Open video file
|
||||
/// \todo leak here, ffmpeg or valgrind bug ?
|
||||
///
|
||||
/// format_ctx->pb->buffer must be freed by hand,
|
||||
/// if not, valgrind will show memleak, see:
|
||||
///
|
||||
/// https://trac.ffmpeg.org/ticket/1357
|
||||
///
|
||||
@ -1023,11 +1025,12 @@ void VideoState::deinit()
|
||||
|
||||
if(this->format_ctx)
|
||||
{
|
||||
// valgrind shows memleak near format_ctx->pb
|
||||
//
|
||||
// As scrawl pointed, memleak could be related to this ffmpeg ticket:
|
||||
// https://trac.ffmpeg.org/ticket/1357
|
||||
//
|
||||
///
|
||||
/// format_ctx->pb->buffer must be freed by hand,
|
||||
/// if not, valgrind will show memleak, see:
|
||||
///
|
||||
/// https://trac.ffmpeg.org/ticket/1357
|
||||
///
|
||||
if (this->format_ctx->pb != NULL)
|
||||
{
|
||||
av_free(this->format_ctx->pb->buffer);
|
||||
|
@ -231,9 +231,9 @@ void FFmpeg_Decoder::close()
|
||||
{
|
||||
if (mFormatCtx->pb != NULL)
|
||||
{
|
||||
// valgrind shows memleak near mFormatCtx->pb
|
||||
// mFormatCtx->pb->buffer must be freed by hand,
|
||||
// if not, valgrind will show memleak, see:
|
||||
//
|
||||
// As scrawl pointed, memleak could be related to this ffmpeg ticket:
|
||||
// https://trac.ffmpeg.org/ticket/1357
|
||||
//
|
||||
if (mFormatCtx->pb->buffer != NULL)
|
||||
|
Loading…
x
Reference in New Issue
Block a user