diff options
Diffstat (limited to 'redist/json_helpers.c')
-rw-r--r-- | redist/json_helpers.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/redist/json_helpers.c b/redist/json_helpers.c index 109708a..8704a93 100644 --- a/redist/json_helpers.c +++ b/redist/json_helpers.c @@ -185,9 +185,6 @@ void json_load_file(const char* path) { char* tag = substr(JSON_STRING, tag_t->start, tag_t->end, JSON_STRING_LEN); char* value = substr(JSON_STRING, value_t->start, value_t->end, JSON_STRING_LEN); - printf("%d %d c:%d %d %s \n", tag_t->start, tag_t->end, tag_t->size, tag_t->type, tag); - - if (value_t->type == JSMN_ARRAY) { i += json_load_array(JSON_STRING, tokens+i+2,value_t->size, tag); //look at array children } else if (value_t->type == JSMN_OBJECT) { @@ -213,6 +210,7 @@ void json_load_file(const char* path) { free(value); } + free(tokens); free(JSON_STRING); } @@ -244,4 +242,4 @@ int parse_float_array(char* str, jsmntok_t* token, FLT** f, uint8_t count) { return count; -}
\ No newline at end of file +} |