summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOri Bernstein <orib@google.com>2013-03-20 12:18:19 -0400
committerOri Bernstein <orib@google.com>2013-03-20 12:18:19 -0400
commit407ef33694a8ac5518297af488759b8f8df19e06 (patch)
tree89cf1b81d7f27eb5a9b97ec0954a6e7cdaca473d
parenta2d39ddf4e0d6dc324bd0af41d89c942f4f8a49c (diff)
downloadmc-407ef33694a8ac5518297af488759b8f8df19e06.tar.gz
Copy the entire union when generating matches.
We don't want uninitialized junk in it's body.
-rw-r--r--6/simp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/6/simp.c b/6/simp.c
index 4521283..3b80cda 100644
--- a/6/simp.c
+++ b/6/simp.c
@@ -532,7 +532,7 @@ static void simpmatch(Simp *s, Node *n)
val = temp(s, n->matchstmt.val);
tmp = rval(s, n->matchstmt.val, val);
if (val != tmp)
- append(s, set(val, tmp));
+ append(s, assign(s, val, tmp));
for (i = 0; i < n->matchstmt.nmatches; i++) {
m = n->matchstmt.matches[i];