summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorVinson Lee <vlee@freedesktop.org>2013-08-04 00:13:53 -0700
committerVinson Lee <vlee@freedesktop.org>2013-08-05 21:53:39 -0700
commit60b567ee59b96b9fa334bf59d3d443c29c590c54 (patch)
treeb461ac9b8c6d8c19ab912e2e8b875abf86db3b58 /src
parent8e850f2febd7b37485675e58e31221fc71080dd4 (diff)
downloadexternal_mesa3d-60b567ee59b96b9fa334bf59d3d443c29c590c54.zip
external_mesa3d-60b567ee59b96b9fa334bf59d3d443c29c590c54.tar.gz
external_mesa3d-60b567ee59b96b9fa334bf59d3d443c29c590c54.tar.bz2
nvc0: Initialize ptr for unexpected sample_count on release builds.
Fixes "Uninitialized pointer read" defect reported by Coverity. Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/nvc0/nvc0_context.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gallium/drivers/nvc0/nvc0_context.c b/src/gallium/drivers/nvc0/nvc0_context.c
index cd86040..8cd5fc5 100644
--- a/src/gallium/drivers/nvc0/nvc0_context.c
+++ b/src/gallium/drivers/nvc0/nvc0_context.c
@@ -394,6 +394,7 @@ nvc0_context_get_sample_position(struct pipe_context *pipe,
case 8: ptr = ms8; break;
default:
assert(0);
+ ptr = ms1;
break;
}
xy[0] = ptr[sample_index][0] * 0.0625f;