Module: wine Branch: master Commit: d686663d22cb027fae7607acf3bae96ab34018f5 URL: https://source.winehq.org/git/wine.git/?a=commit;h=d686663d22cb027fae7607acf...
Author: Nikolay Sivov nsivov@codeweavers.com Date: Tue May 10 19:16:18 2022 +0300
evr/sample: Use explicit critical section for release handling.
Signed-off-by: Nikolay Sivov nsivov@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/evr/sample.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/evr/sample.c b/dlls/evr/sample.c index 738f803fe66..3521e6c4d51 100644 --- a/dlls/evr/sample.c +++ b/dlls/evr/sample.c @@ -923,7 +923,7 @@ static ULONG WINAPI video_sample_Release(IMFSample *iface) ULONG refcount = InterlockedDecrement(&sample->refcount); IMFAsyncResult *tracked_result = NULL;
- IMFSample_LockStore(sample->sample); + EnterCriticalSection(&sample->cs); if (sample->tracked_result && sample->tracked_refcount == refcount) { tracked_result = sample->tracked_result; @@ -931,7 +931,7 @@ static ULONG WINAPI video_sample_Release(IMFSample *iface) sample->tracked_result = NULL; sample->tracked_refcount = 0; } - IMFSample_UnlockStore(sample->sample); + LeaveCriticalSection(&sample->cs);
if (tracked_result) IMFAsyncResult_Release(tracked_result);