From f04fe23a5256cc82c383f2949ead78cb7cc9228d Mon Sep 17 00:00:00 2001 From: Lukasz Marek Date: Tue, 12 Nov 2013 22:38:14 +0100 Subject: lavd/xv: fix memory leak Results of XvQueryAdaptors have to be freed with XvFreeAdaptorInfo. Signed-off-by: Lukasz Marek --- libavdevice/xv.c | 1 + 1 file changed, 1 insertion(+) (limited to 'libavdevice') diff --git a/libavdevice/xv.c b/libavdevice/xv.c index 3b377f8bdb..50d72a5f8d 100644 --- a/libavdevice/xv.c +++ b/libavdevice/xv.c @@ -97,6 +97,7 @@ static int xv_write_header(AVFormatContext *s) if (XvQueryAdaptors(xv->display, DefaultRootWindow(xv->display), &num_adaptors, &ai) != Success) return AVERROR_EXTERNAL; xv->xv_port = ai[0].base_id; + XvFreeAdaptorInfo(ai); if (encctx->pix_fmt != AV_PIX_FMT_YUV420P) { av_log(s, AV_LOG_ERROR, -- cgit v1.2.3