Mesa (master): glsl: Fix cut-and-paste bug in hierarchical visitor ir_expression::accept

Ian Romanick idr at kemper.freedesktop.org
Tue Sep 27 19:07:02 UTC 2016


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

Author: Ian Romanick <ian.d.romanick at intel.com>
Date:   Thu Sep 15 11:11:12 2016 -0700

glsl: Fix cut-and-paste bug in hierarchical visitor ir_expression::accept

At this point in the code, s must be visit_continue.  If the child
returned visit_stop, visit_stop is the only correct thing to return.

Found by inspection.

Signed-off-by: Ian Romanick <ian.d.romanick at intel.com>
Cc: mesa-stable at lists.freedesktop.org
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>

---

 src/compiler/glsl/ir_hv_accept.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/compiler/glsl/ir_hv_accept.cpp b/src/compiler/glsl/ir_hv_accept.cpp
index 213992a..5cc6a34 100644
--- a/src/compiler/glsl/ir_hv_accept.cpp
+++ b/src/compiler/glsl/ir_hv_accept.cpp
@@ -147,7 +147,7 @@ ir_expression::accept(ir_hierarchical_visitor *v)
 	 goto done;
 
       case visit_stop:
-	 return s;
+	 return visit_stop;
       }
    }
 




More information about the mesa-commit mailing list