diff options
author | Karl Schultz <[email protected]> | 2003-09-18 15:14:10 +0000 |
---|---|---|
committer | Karl Schultz <[email protected]> | 2003-09-18 15:14:10 +0000 |
commit | df8d337eec9b9f6f1d6ed0b4a7044b4f4420c52b (patch) | |
tree | b9a0b26cc589758e68ddb0801d6b9ca1e7dd1b47 /src/mesa/main/bufferobj.c | |
parent | 65f605849af1a14eaa79dab6c9d80575d5c85db0 (diff) |
Add casts to prevent signed/unsigned compare compiler warnings.
Diffstat (limited to 'src/mesa/main/bufferobj.c')
-rw-r--r-- | src/mesa/main/bufferobj.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c index 57e6b8df23c..3ae35d5b4d5 100644 --- a/src/mesa/main/bufferobj.c +++ b/src/mesa/main/bufferobj.c @@ -110,7 +110,7 @@ buffer_object_subdata_range_good( GLcontext * ctx, GLenum target, return NULL; } - if ( (offset + size) > bufObj->Size ) { + if ( (GLuint)(offset + size) > bufObj->Size ) { _mesa_error(ctx, GL_INVALID_VALUE, "%s(size + offset > buffer size)", str); return NULL; @@ -261,7 +261,7 @@ _mesa_buffer_subdata( GLcontext *ctx, GLenum target, GLintptrARB offset, struct gl_buffer_object * bufObj ) { if ( (bufObj->Data != NULL) - && ((size + offset) <= bufObj->Size) ) { + && ((GLuint)(size + offset) <= bufObj->Size) ) { _mesa_memcpy( (GLubyte *) bufObj->Data + offset, data, size ); } } @@ -291,7 +291,7 @@ _mesa_buffer_get_subdata( GLcontext *ctx, GLenum target, GLintptrARB offset, struct gl_buffer_object * bufObj ) { if ( (bufObj->Data != NULL) - && ((size + offset) <= bufObj->Size) ) { + && ((GLuint)(size + offset) <= bufObj->Size) ) { _mesa_memcpy( data, (GLubyte *) bufObj->Data + offset, size ); } } @@ -428,7 +428,7 @@ void _mesa_DeleteBuffersARB(GLsizei n, const GLuint *ids) { GET_CURRENT_CONTEXT(ctx); - unsigned i; + GLsizei i; ASSERT_OUTSIDE_BEGIN_END(ctx); if (n < 0) { |