Merge pull request #764 from ikrima/fix-malloc-call

fix: ts_subtree_string not using ts_malloc
This commit is contained in:
Max Brunsfeld 2020-10-15 23:50:37 -07:00 committed by GitHub
commit 135c630e92
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -902,7 +902,7 @@ char *ts_subtree_string(
language, include_all,
0, false, ROOT_FIELD
) + 1;
char *result = malloc(size * sizeof(char));
char *result = ts_malloc(size * sizeof(char));
ts_subtree__write_to_string(
self, result, size,
language, include_all,