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>
This commit is contained in:
Zebediah Figura 2020-05-04 18:05:23 -05:00 committed by Alexandre Julliard
parent 9181a12e62
commit e7ed2798e8
2 changed files with 4 additions and 1 deletions

View File

@ -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);

View File

@ -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);