Module: wine Branch: master Commit: e7ed2798e863c2ac56aabf654c61c912e31a4a7f URL: https://source.winehq.org/git/wine.git/?a=commit;h=e7ed2798e863c2ac56aabf654...
Author: Zebediah Figura z.figura12@gmail.com Date: Mon May 4 18:05:23 2020 -0500
quartz/vmr9: Call IVMRSurfaceAllocator9::TerminateDevice() when destroying the filter.
Signed-off-by: Zebediah Figura z.figura12@gmail.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/quartz/tests/vmr9.c | 2 +- dlls/quartz/vmr9.c | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/dlls/quartz/tests/vmr9.c b/dlls/quartz/tests/vmr9.c index c0fb6a6f34..5c08868fc0 100644 --- a/dlls/quartz/tests/vmr9.c +++ b/dlls/quartz/tests/vmr9.c @@ -3272,7 +3272,7 @@ static void test_surface_allocator_notify_refcount(void)
ref = IBaseFilter_Release(filter); ok(!ref, "Got outstanding refcount %d.\n", ref); - todo_wine ok(allocator_got_TerminateDevice == 1, "Got %u calls to TerminateDevice().\n", + ok(allocator_got_TerminateDevice == 1, "Got %u calls to TerminateDevice().\n", allocator_got_TerminateDevice); ok(allocator_refcount == 1, "Got outstanding refcount %d.\n", allocator_refcount);
diff --git a/dlls/quartz/vmr9.c b/dlls/quartz/vmr9.c index a8f88e3d04..4fd3e70b96 100644 --- a/dlls/quartz/vmr9.c +++ b/dlls/quartz/vmr9.c @@ -595,7 +595,10 @@ static void vmr_destroy(struct strmbase_renderer *iface) InterlockedIncrement(&filter->renderer.filter.refcount);
if (filter->allocator) + { + IVMRSurfaceAllocatorEx9_TerminateDevice(filter->allocator, filter->cookie); IVMRSurfaceAllocatorEx9_Release(filter->allocator); + } if (filter->presenter) IVMRImagePresenter9_Release(filter->presenter);