mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-08 06:20:19 +01:00
st/nine: Prevent crash in GetRenderTargetData
Return error instead of crashing on source surfaces with format D3DFMT_NULL. Fix for issue #236. Tested on Windows 7. Signed-off-by: Patrick Rudolph <siro@das-labor.org> Reviewed-by: Axel Davy <axel.davy@ens.fr>
This commit is contained in:
parent
09edc0555f
commit
5d85253dc3
1 changed files with 2 additions and 0 deletions
|
|
@ -1464,6 +1464,8 @@ NineDevice9_GetRenderTargetData( struct NineDevice9 *This,
|
|||
user_assert(src->desc.Width == dst->desc.Width, D3DERR_INVALIDCALL);
|
||||
user_assert(src->desc.Height == dst->desc.Height, D3DERR_INVALIDCALL);
|
||||
|
||||
user_assert(src->desc.Format != D3DFMT_NULL, D3DERR_INVALIDCALL);
|
||||
|
||||
NineSurface9_CopyDefaultToMem(dst, src);
|
||||
|
||||
return D3D_OK;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue