d3d: Remove AddRef from IWineD3DDevice_GetDepthStencilSurface.
This commit is contained in:
parent
a7518f6f54
commit
18546a65e6
|
@ -698,7 +698,6 @@ static HRESULT WINAPI IDirect3DDevice8Impl_GetDepthStencilSurface(LPDIRECT3DDE
|
||||||
hr=IWineD3DDevice_GetDepthStencilSurface(This->WineD3DDevice,&pZStencilSurface);
|
hr=IWineD3DDevice_GetDepthStencilSurface(This->WineD3DDevice,&pZStencilSurface);
|
||||||
if(hr == D3D_OK && pZStencilSurface != NULL){
|
if(hr == D3D_OK && pZStencilSurface != NULL){
|
||||||
IWineD3DResource_GetParent((IWineD3DResource *)pZStencilSurface,(IUnknown**)ppZStencilSurface);
|
IWineD3DResource_GetParent((IWineD3DResource *)pZStencilSurface,(IUnknown**)ppZStencilSurface);
|
||||||
IWineD3DResource_Release((IWineD3DResource *)pZStencilSurface);
|
|
||||||
}else{
|
}else{
|
||||||
FIXME("Call to IWineD3DDevice_GetDepthStencilSurface failed\n");
|
FIXME("Call to IWineD3DDevice_GetDepthStencilSurface failed\n");
|
||||||
*ppZStencilSurface = NULL;
|
*ppZStencilSurface = NULL;
|
||||||
|
|
|
@ -433,7 +433,6 @@ static HRESULT WINAPI IDirect3DDevice9Impl_GetDepthStencilSurface(LPDIRECT3DDE
|
||||||
hr=IWineD3DDevice_GetDepthStencilSurface(This->WineD3DDevice,&pZStencilSurface);
|
hr=IWineD3DDevice_GetDepthStencilSurface(This->WineD3DDevice,&pZStencilSurface);
|
||||||
if(hr == D3D_OK && pZStencilSurface != NULL){
|
if(hr == D3D_OK && pZStencilSurface != NULL){
|
||||||
IWineD3DResource_GetParent((IWineD3DResource *)pZStencilSurface,(IUnknown**)ppZStencilSurface);
|
IWineD3DResource_GetParent((IWineD3DResource *)pZStencilSurface,(IUnknown**)ppZStencilSurface);
|
||||||
IWineD3DResource_Release((IWineD3DResource *)pZStencilSurface);
|
|
||||||
}else{
|
}else{
|
||||||
FIXME("Call to IWineD3DDevice_GetRenderTarget failed\n");
|
FIXME("Call to IWineD3DDevice_GetRenderTarget failed\n");
|
||||||
*ppZStencilSurface = NULL;
|
*ppZStencilSurface = NULL;
|
||||||
|
|
|
@ -6981,10 +6981,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_GetDepthStencilSurface(IWineD3DDevice
|
||||||
*ppZStencilSurface = This->depthStencilBuffer;
|
*ppZStencilSurface = This->depthStencilBuffer;
|
||||||
TRACE("(%p) : zStencilSurface returning %p\n", This, *ppZStencilSurface);
|
TRACE("(%p) : zStencilSurface returning %p\n", This, *ppZStencilSurface);
|
||||||
|
|
||||||
if(*ppZStencilSurface != NULL) {
|
|
||||||
/* Note inc ref on returned surface */
|
|
||||||
IWineD3DSurface_AddRef(*ppZStencilSurface);
|
|
||||||
}
|
|
||||||
return WINED3D_OK;
|
return WINED3D_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue