Commit bac34c35 authored by H. Verbeet's avatar H. Verbeet Committed by Alexandre Julliard

wined3d: Release the container during surface / volume cleanup.

parent 75ac954c
......@@ -69,6 +69,9 @@ ULONG WINAPI IWineD3DSurfaceImpl_Release(IWineD3DSurface *iface) {
glDeleteTextures(1, &This->glDescription.textureName);
LEAVE_GL();
}
if (This->container) {
IWineD3DBase_Release(This->container);
}
IWineD3DResourceImpl_CleanUp((IWineD3DResource *)iface);
TRACE("(%p) Released\n", This);
......
......@@ -55,6 +55,9 @@ ULONG WINAPI IWineD3DVolumeImpl_Release(IWineD3DVolume *iface) {
TRACE("(%p) : Releasing from %ld\n", This, This->resource.ref);
ref = InterlockedDecrement(&This->resource.ref);
if (ref == 0) {
if (This->container) {
IWineD3DBase_Release(This->container);
}
IWineD3DResourceImpl_CleanUp((IWineD3DResource *)iface);
HeapFree(GetProcessHeap(), 0, This);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment