From: sparky4 Date: Sun, 22 Mar 2015 17:01:24 +0000 (-0500) Subject: modified: src/lib/jsmn/example/MAPTEST.EXE X-Git-Url: http://4ch.mooo.com/gitweb/?a=commitdiff_plain;h=26f2df76eb4c3fcd0defded7c873b87f2548d3a6;p=16.git modified: src/lib/jsmn/example/MAPTEST.EXE modified: src/lib/jsmn/example/maptest.c --- diff --git a/src/lib/jsmn/example/MAPTEST.EXE b/src/lib/jsmn/example/MAPTEST.EXE index 697c8c9e..884e5f67 100644 Binary files a/src/lib/jsmn/example/MAPTEST.EXE and b/src/lib/jsmn/example/MAPTEST.EXE differ diff --git a/src/lib/jsmn/example/maptest.c b/src/lib/jsmn/example/maptest.c index 9de99e28..942402fa 100644 --- a/src/lib/jsmn/example/maptest.c +++ b/src/lib/jsmn/example/maptest.c @@ -13,6 +13,7 @@ "\"groups\": [\"users\", \"wheel\", \"audio\", \"video\"]}";*/ char *JSON_STRING; +char JSON_S[6144]; long int filesize(FILE *fp) { @@ -39,8 +40,7 @@ int main() { jsmn_parser p; FILE *fh = fopen("../../../../data/test.map", "r"); jsmntok_t t[1536]; /* We expect no more than 128 tokens */ - char JSON_S[6144]; - memset(JSON_S, 0, sizeof(JSON_S)); + //memset(JSON_S, 0, sizeof(JSON_S)); if(fh != NULL) { @@ -53,7 +53,7 @@ int main() { jsmn_init(&p); r = jsmn_parse(&p, JSON_STRING, filesize(fh), t, sizeof(t)/sizeof(t[0])); fclose(fh); fh = NULL; - printf("%s", JSON_STRING); + //printf("%s", JSON_STRING); if (r < 0) { printf("Failed to parse JSON: %d\n", r); return 1;