Browse Source

prevent false freeing of vector

pre-master-46
Holger Vogt 6 years ago
parent
commit
89ea46e39a
  1. 2
      src/frontend/parse.c

2
src/frontend/parse.c

@ -471,7 +471,7 @@ void free_pnode_x(struct pnode *t)
free_pnode(t->pn_right);
free_pnode(t->pn_next);
tfree(t->pn_name); /* va: it is a copy() of original string, can be free'd */
if (t->pn_value && !(t->pn_value->v_flags & VF_PERMANENT)) {
if (t->pn_use == 1 && t->pn_value && !(t->pn_value->v_flags & VF_PERMANENT)) {
vec_free(t->pn_value); /* patch by Stefan Jones */
}
txfree(t);

Loading…
Cancel
Save