wined3d: Avoid crashing when ProcessVertices is called with NULL vertex declaration.

This commit is contained in:
Paul Chitescu 2006-09-04 17:16:45 +03:00 committed by Alexandre Julliard
parent 778d5d65e8
commit 4a581e6030

View file

@ -5437,6 +5437,10 @@ static HRESULT WINAPI IWineD3DDeviceImpl_ProcessVertices(IWineD3DDevice *iface,
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