Zhiyi Zhang : evr: Release buffer after adding it to sample.

Alexandre Julliard julliard at winehq.org
Thu Jun 30 16:34:20 CDT 2022


Module: wine
Branch: master
Commit: 86034654a8323ae38ecbd1ac6e5424ca7de4f1eb
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=86034654a8323ae38ecbd1ac6e5424ca7de4f1eb

Author: Zhiyi Zhang <zzhang at codeweavers.com>
Date:   Wed Jun 29 17:46:18 2022 +0800

evr: Release buffer after adding it to sample.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53201
Signed-off-by: Zhiyi Zhang <zzhang at codeweavers.com>

---

 dlls/evr/sample.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/dlls/evr/sample.c b/dlls/evr/sample.c
index f03292704b5..6a1bbf564f5 100644
--- a/dlls/evr/sample.c
+++ b/dlls/evr/sample.c
@@ -1747,7 +1747,10 @@ HRESULT WINAPI MFCreateVideoSampleFromSurface(IUnknown *surface, IMFSample **sam
     }
 
     if (buffer)
+    {
         IMFSample_AddBuffer(object->sample, buffer);
+        IMFMediaBuffer_Release(buffer);
+    }
 
     video_sample_create_tracking_thread();
 




More information about the wine-cvs mailing list