From f1b7a528ec3077917fd2c82183b6519769b46529 Mon Sep 17 00:00:00 2001 From: Haihao Xiang Date: Wed, 15 Nov 2023 12:13:44 +0800 Subject: [PATCH] vpp: avoid double free Free() is called in the deconstructor of MfxFrameAllocResponse Signed-off-by: Haihao Xiang --- _studio/mfx_lib/vpp/src/mfx_vpp_hw.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/_studio/mfx_lib/vpp/src/mfx_vpp_hw.cpp b/_studio/mfx_lib/vpp/src/mfx_vpp_hw.cpp index b451fbcdb5..41d051da95 100644 --- a/_studio/mfx_lib/vpp/src/mfx_vpp_hw.cpp +++ b/_studio/mfx_lib/vpp/src/mfx_vpp_hw.cpp @@ -3292,8 +3292,9 @@ mfxStatus VideoVPPHW::Close() { mfxStatus sts = MFX_ERR_NONE; - m_internalVidSurf[VPP_IN].Free(); - m_internalVidSurf[VPP_OUT].Free(); + // Free() is called in MfxFrameAllocResponse::~MfxFrameAllocResponse() + // m_internalVidSurf[VPP_IN].Free(); + // m_internalVidSurf[VPP_OUT].Free(); m_executeSurf.clear();