summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r600
diff options
context:
space:
mode:
authorVinson Lee <[email protected]>2013-09-27 23:05:54 -0700
committerVinson Lee <[email protected]>2013-09-30 10:27:52 -0700
commit114ae4747549b5677cca0dbd2b8c8531d8789c49 (patch)
tree9a3133f60e9677bfca8fc93f7278382bf1e3e8fe /src/gallium/drivers/r600
parent0d441aac3d28e58b54b25a6dcd4c4cb086f9725d (diff)
r600g/sb: Move variable dereference after null check.
Fixes "Deference before null check" defect reported by Coverity. Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Vadim Girlin <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r600')
-rw-r--r--src/gallium/drivers/r600/sb/sb_ra_init.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/drivers/r600/sb/sb_ra_init.cpp b/src/gallium/drivers/r600/sb/sb_ra_init.cpp
index 0b332a9847a..e53aba540de 100644
--- a/src/gallium/drivers/r600/sb/sb_ra_init.cpp
+++ b/src/gallium/drivers/r600/sb/sb_ra_init.cpp
@@ -395,11 +395,12 @@ void ra_init::color_bs_constraint(ra_constraint* c) {
for (vvec::iterator I = vv.begin(), E = vv.end(); I != E; ++I) {
value *v = *I;
- sel_chan gpr = v->get_final_gpr();
if (!v || v->is_dead())
continue;
+ sel_chan gpr = v->get_final_gpr();
+
val_set interf;
if (v->chunk)