diff options
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) { |