dlls/wined3d/state.c -- fix error handling
Gerald Pfeifer
gerald at pfeifer.com
Mon Dec 3 18:34:55 CST 2007
This looks like a mistaken consistency check. The code where mapped_stage
is set looks as follows:
DWORD mapped_stage = stateblock->wineD3DDevice->texUnitMap[texUnit];
and at other places we do check for -1, so this looks like another bug
in error handling.
Gerald
ChangeLog:
Fix error handling in transform_texture().
Index: dlls/wined3d/state.c
===================================================================
RCS file: /home/wine/wine/dlls/wined3d/state.c,v
retrieving revision 1.231
diff -u -3 -p -r1.231 state.c
--- dlls/wined3d/state.c 29 Nov 2007 16:32:47 -0000 1.231
+++ dlls/wined3d/state.c 4 Dec 2007 00:33:58 -0000
@@ -1957,7 +1957,7 @@ static void transform_texture(DWORD stat
return;
}
- if (mapped_stage < 0) return;
+ if (mapped_stage == -1) return;
if (GL_SUPPORT(ARB_MULTITEXTURE)) {
if(mapped_stage >= GL_LIMITS(textures)) {
More information about the wine-patches
mailing list