summaryrefslogtreecommitdiff
path: root/mi/match.c
diff options
context:
space:
mode:
authorMura Li <mura_li@castech.com.tw>2020-04-22 09:30:59 +0000
committerOri Bernstein <ori@eigenstate.org>2020-05-05 20:33:19 -0700
commit9ef8abbefa9171d713fba46d8f84ac0000cb758b (patch)
tree15dc3efff80153b91cb09cd3360fd58d3a96af31 /mi/match.c
parent49b61a099de4734e638b1122a5542dd616edd462 (diff)
downloadmc-9ef8abbefa9171d713fba46d8f84ac0000cb758b.tar.gz
Fix missing link of linked list
Diffstat (limited to 'mi/match.c')
-rw-r--r--mi/match.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/mi/match.c b/mi/match.c
index de2a9b7..1d69eda 100644
--- a/mi/match.c
+++ b/mi/match.c
@@ -459,6 +459,8 @@ addrec(Frontier *fs, Node *pat, Node *val, Path *path)
switch (exprop(pat)) {
case Olor:
next = frontierdup(fs);
+ if (fs->next)
+ next->next = fs->next;
fs->next = next;
addrec(fs, pat->expr.args[1], val, path);
addrec(next, pat->expr.args[0], val, path);