Module: wine Branch: master Commit: 4a581e6030b1b257c787b6efa145a099dd2ef513 URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=4a581e6030b1b257c787b6ef... Author: Paul Chitescu <pchitescu(a)voip.null.ro> Date: Mon Sep 4 17:16:45 2006 +0300 wined3d: Avoid crashing when ProcessVertices is called with NULL vertex declaration. --- dlls/wined3d/device.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index be90664..c939aa3 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -5437,6 +5437,10 @@ static HRESULT WINAPI IWineD3DDeviceImpl WineDirect3DVertexStridedData strided; TRACE("(%p)->(%d,%d,%d,%p,%p,%ld\n", This, SrcStartIndex, DestIndex, VertexCount, pDestBuffer, pVertexDecl, Flags); + if (!SrcImpl) { + WARN("NULL source vertex buffer\n"); + return WINED3DERR_INVALIDCALL; + } /* We don't need the source vbo because this buffer is only used as * a source for ProcessVertices. Avoid wasting resources by converting the * buffer and loading the VBO