[Mesa-dev] [PATCH 2/4] nvc0: Silence uninitialized variable warning in the release build
Emil Velikov
emil.l.velikov at gmail.com
Sat Jun 22 08:43:36 PDT 2013
Resolves the following gcc warning
warning: 'ptr' may be used uninitialized in this function
xy[0] = ptr[sample_index][0] * 0.0625f;
^
Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
---
src/gallium/drivers/nvc0/nvc0_context.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/gallium/drivers/nvc0/nvc0_context.c b/src/gallium/drivers/nvc0/nvc0_context.c
index cd86040..1b776f9 100644
--- a/src/gallium/drivers/nvc0/nvc0_context.c
+++ b/src/gallium/drivers/nvc0/nvc0_context.c
@@ -393,6 +393,7 @@ nvc0_context_get_sample_position(struct pipe_context *pipe,
case 4: ptr = ms4; break;
case 8: ptr = ms8; break;
default:
+ ptr = ms1;
assert(0);
break;
}
--
1.8.3.1
More information about the mesa-dev
mailing list