From 0b69e4837ebf795ba0dbd56d610fc3bd94363f34 Mon Sep 17 00:00:00 2001 From: Ian Romanick Date: Mon, 13 Nov 2006 23:34:35 +0000 Subject: [PATCH] Clean-up compiler warnings. --- src/mesa/drivers/dri/tdfx/tdfx_tex.c | 2 +- src/mesa/drivers/dri/tdfx/tdfx_texstate.c | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/tdfx/tdfx_tex.c b/src/mesa/drivers/dri/tdfx/tdfx_tex.c index c3fe7bebd3e..89865d96379 100644 --- a/src/mesa/drivers/dri/tdfx/tdfx_tex.c +++ b/src/mesa/drivers/dri/tdfx/tdfx_tex.c @@ -1755,7 +1755,7 @@ tdfxCompressedTexSubImage2D( GLcontext *ctx, GLenum target, for (i = 0; i < rows; i++) { MEMCPY(dest, data, srcRowStride); dest += destRowStride; - data = (GLvoid *)((GLuint)data + (GLuint)srcRowStride); + data = (GLvoid *)((intptr_t)data + (intptr_t)srcRowStride); } /* [dBorca] Hack alert: diff --git a/src/mesa/drivers/dri/tdfx/tdfx_texstate.c b/src/mesa/drivers/dri/tdfx/tdfx_texstate.c index f5f385fad7c..fda9ce56849 100644 --- a/src/mesa/drivers/dri/tdfx/tdfx_texstate.c +++ b/src/mesa/drivers/dri/tdfx/tdfx_texstate.c @@ -1015,9 +1015,12 @@ SetupSingleTexEnvVoodoo3(GLcontext *ctx, int unit, } break; - default: + default: { + (void) memcpy(&colorComb, &fxMesa->ColorCombine, sizeof(colorComb)); + (void) memcpy(&alphaComb, &fxMesa->AlphaCombine, sizeof(alphaComb)); _mesa_problem(ctx, "bad texture env mode in %s", __FUNCTION__); } + } if (colorComb.Function != fxMesa->ColorCombine.Function || colorComb.Factor != fxMesa->ColorCombine.Factor || -- 2.30.2