Module: wine Branch: master Commit: d8c40f76414929e7f87e737f7baed0751279bb4a URL: http://source.winehq.org/git/wine.git/?a=commit;h=d8c40f76414929e7f87e737f7b...
Author: Henri Verbeet hverbeet@codeweavers.com Date: Tue Oct 7 16:01:01 2008 +0200
wined3d: Print an error when drawStridedSlow() is called with 0 idxSize and non-NULL idxData (CID 509).
---
dlls/wined3d/drawprim.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/dlls/wined3d/drawprim.c b/dlls/wined3d/drawprim.c index 95af758..512d85c 100644 --- a/dlls/wined3d/drawprim.c +++ b/dlls/wined3d/drawprim.c @@ -318,6 +318,9 @@ static void drawStridedSlow(IWineD3DDevice *iface, WineDirect3DVertexStridedData
if (idxSize == 2) pIdxBufS = (const WORD *) idxData; else pIdxBufL = (const DWORD *) idxData; + } else if (idxData) { + ERR("non-NULL idxData with 0 idxSize, this should never happen\n"); + return; }
/* Adding the stream offset once is cheaper than doing it every iteration. Do not modify the strided data, it is a pointer