summaryrefslogtreecommitdiff
path: root/parse/use.c
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2017-06-18 13:00:43 -0700
committerOri Bernstein <ori@eigenstate.org>2017-06-18 13:57:18 -0700
commit763778b6ec6d13744cecedde5ee35675acfcb4ed (patch)
treed875c172f0442f4bdb59e17b0f2621bde7587bb7 /parse/use.c
parent3e8c358141a5fabeec1db153a5762eb28f571a76 (diff)
downloadmc-763778b6ec6d13744cecedde5ee35675acfcb4ed.tar.gz
Prevent traitfixtype from getting out of sync
These arrays are always appended to at the same time, and fixtraitmappings relies on their indices corresponding. Previously, only traitfixdest and traitfixid were cleared at the end of fixtraitmappings, causing traits to get added to incorrect types.
Diffstat (limited to 'parse/use.c')
-rw-r--r--parse/use.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/parse/use.c b/parse/use.c
index ae3a68b..c547371 100644
--- a/parse/use.c
+++ b/parse/use.c
@@ -822,6 +822,7 @@ static void fixtraitmappings(Stab *st)
}
lfree(&traitfixdest, &ntraitfixdest);
+ lfree(&traitfixtype, &ntraitfixtype);
lfree(&traitfixid, &ntraitfixid);
}