Fix memory leak in tree
This commit is contained in:
parent
7251456cd2
commit
8deeff392b
4 changed files with 12 additions and 7 deletions
|
|
@ -49,7 +49,7 @@ void ts_tree_release(ts_tree *tree) {
|
|||
ts_tree **children = tree->data.children.contents;
|
||||
for (int i = 0; i < ts_tree_child_count(tree); i++)
|
||||
ts_tree_release(children[i]);
|
||||
// free(children);
|
||||
free(children);
|
||||
free(tree);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue