From: Rhys Kidd Date: Thu, 6 Aug 2015 06:34:13 +0000 (+1000) Subject: i965: Resolve GCC sign-compare warning. X-Git-Tag: upstream/17.1.0~16815 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5fb58012be6f783d735ded79582aa46a2c71e0fd;p=platform%2Fupstream%2Fmesa.git i965: Resolve GCC sign-compare warning. mesa/src/mesa/drivers/dri/i965/brw_wm_surface_state.c: In function 'brw_upload_ubo_surfaces': mesa/src/mesa/drivers/dri/i965/brw_wm_surface_state.c:901:22: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for (int i = 0; i < shader->NumUniformBlocks; i++) { ^ Signed-off-by: Rhys Kidd Reviewed-by: Thomas Helland --- diff --git a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c index f13a97c..2b8692a 100644 --- a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c +++ b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c @@ -898,7 +898,7 @@ brw_upload_ubo_surfaces(struct brw_context *brw, uint32_t *surf_offsets = &stage_state->surf_offset[prog_data->binding_table.ubo_start]; - for (int i = 0; i < shader->NumUniformBlocks; i++) { + for (unsigned i = 0; i < shader->NumUniformBlocks; i++) { struct gl_uniform_buffer_binding *binding; struct intel_buffer_object *intel_bo;