[Mesa-dev] [PATCH] i965: Silece usused variable warning in release build

Chad Versace chad.versace at linux.intel.com
Tue Aug 27 15:11:59 PDT 2013


Use `(void) success;` to silence this warning:

  i965/brw_vs.c:481:12:
  warning: unused variable 'success' [-Wunused-variable]
         bool success = do_vs_prog(brw, ctx->Shader.CurrentVertexProgram,

Signed-off-by: Chad Versace <chad.versace at linux.intel.com>
---
 src/mesa/drivers/dri/i965/brw_vs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/drivers/dri/i965/brw_vs.c b/src/mesa/drivers/dri/i965/brw_vs.c
index c4e016b..e0adc1d 100644
--- a/src/mesa/drivers/dri/i965/brw_vs.c
+++ b/src/mesa/drivers/dri/i965/brw_vs.c
@@ -480,7 +480,7 @@ static void brw_upload_vs_prog(struct brw_context *brw)
 			 &brw->vs.prog_offset, &brw->vs.prog_data)) {
       bool success = do_vs_prog(brw, ctx->Shader.CurrentVertexProgram,
 				vp, &key);
-
+      (void) success;
       assert(success);
    }
    if (memcmp(&brw->vs.prog_data->base.vue_map, &brw->vue_map_geom_out,
-- 
1.8.3.1



More information about the mesa-dev mailing list