ref: 397e7774d4a6a7353d1c2c2bc5c68f90ebacab75
parent: 9783cadd19045e7d3f5b5eaaad8feb5ebeacb042
author: Ori Bernstein <[email protected]>
date: Fri Sep 13 09:53:56 EDT 2013
Fix crashes in unpickling match stmts.
--- a/parse/use.c
+++ b/parse/use.c
@@ -490,6 +490,7 @@
case Nmatchstmt:
n->matchstmt.val = unpickle(fd);
n->matchstmt.nmatches = rdint(fd);
+ n->matchstmt.matches = zalloc(sizeof(Node *)*n->matchstmt.nmatches);
for (i = 0; i < n->matchstmt.nmatches; i++)
n->matchstmt.matches[i] = unpickle(fd);
break;