mirror of
https://github.com/owntracks/recorder.git
synced 2026-08-27 16:57:21 +00:00
free after using slurped file
This commit is contained in:
@@ -165,10 +165,12 @@ int json_copy_from_file(JsonNode *obj, char *filename)
|
||||
|
||||
if ((node = json_decode(js_string)) == NULL) {
|
||||
fprintf(stderr, "json_copy_from_file can't decode JSON from %s\n", filename);
|
||||
free(js_string);
|
||||
return (FALSE);
|
||||
}
|
||||
json_copy_to_object(obj, node, FALSE);
|
||||
json_delete(node);
|
||||
free(js_string);
|
||||
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user