Mesa (master): llvmpipe: Fix bad logic.

Jose Fonseca jrfonseca at kemper.freedesktop.org
Wed Jun 2 20:34:20 UTC 2010


Module: Mesa
Branch: master
Commit: a33b5ef7d02a45bda106065e7c927358b04fe289
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=a33b5ef7d02a45bda106065e7c927358b04fe289

Author: José Fonseca <jfonseca at vmware.com>
Date:   Wed Jun  2 20:09:02 2010 +0100

llvmpipe: Fix bad logic.

Courtesy of Vinson and coverity.

---

 src/gallium/drivers/llvmpipe/lp_bld_interp.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/gallium/drivers/llvmpipe/lp_bld_interp.c b/src/gallium/drivers/llvmpipe/lp_bld_interp.c
index 957866e..90d2b26 100644
--- a/src/gallium/drivers/llvmpipe/lp_bld_interp.c
+++ b/src/gallium/drivers/llvmpipe/lp_bld_interp.c
@@ -262,7 +262,7 @@ attribs_update(struct lp_build_interp_soa_context *bld, int quad_index)
       for(chan = 0; chan < NUM_CHANNELS; ++chan) {
          if(mask & (1 << chan)) {
             LLVMValueRef a = coeff_bld->undef;
-            if (interp == LP_INTERP_CONSTANT &&
+            if (interp == LP_INTERP_CONSTANT ||
                 interp == LP_INTERP_FACING) {
                a = bld->a[attrib][chan];
             }




More information about the mesa-commit mailing list