summaryrefslogtreecommitdiff
path: root/src/mesa/main/program.c
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2003-09-19 15:38:15 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2003-09-19 15:38:15 +0000
commite4fcea2e06571b71a85b4f100c95d866a82f7c19 (patch)
treedf95d1d9eed897c1dd2fee2923163843ddca3228 /src/mesa/main/program.c
parent74c33393b4ebcc1616c0d8f1b6f43d658aed3f22 (diff)
Assorted casts to silence g++ warnings.
Diffstat (limited to 'src/mesa/main/program.c')
-rw-r--r--src/mesa/main/program.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/mesa/main/program.c b/src/mesa/main/program.c
index 8cc5f6885a..fa5f301e2a 100644
--- a/src/mesa/main/program.c
+++ b/src/mesa/main/program.c
@@ -260,9 +260,10 @@ add_parameter(struct program_parameter_list *paramList,
{
const GLuint n = paramList->NumParameters;
- paramList->Parameters = _mesa_realloc(paramList->Parameters,
- n * sizeof(struct program_parameter),
- (n + 1) * sizeof(struct program_parameter));
+ paramList->Parameters = (struct program_parameter *)
+ _mesa_realloc(paramList->Parameters,
+ n * sizeof(struct program_parameter),
+ (n + 1) * sizeof(struct program_parameter));
if (!paramList->Parameters) {
/* out of memory */
paramList->NumParameters = 0;
@@ -1011,7 +1012,7 @@ _mesa_GetProgramRegisterfvMESA(GLenum target,
#endif
/* make null-terminated copy of registerName */
- len = MIN2(len, sizeof(reg) - 1);
+ len = MIN2((unsigned int) len, sizeof(reg) - 1);
_mesa_memcpy(reg, registerName, len);
reg[len] = 0;