--- libelwix/example/test_json.c 2017/11/28 00:46:53 1.1.2.1 +++ libelwix/example/test_json.c 2017/11/28 02:05:21 1.1.2.3 @@ -10,7 +10,7 @@ int run_simple(json_t *json) { static const char *teststr = "{\"user\": \"johndoe\", \"admin\": false, \"uid\": 1000,\n " - "\"groups\": [\"users\", \"wheel\", \"audio\", \"video\"]}"; + "\"groups\": [\"users\", \"\", \"wheel\", \"audio\", \"video\"]}"; int i, ret; jtok_t *tok, toks[20]; ait_val_t *v; @@ -37,7 +37,7 @@ run_simple(json_t *json) printf("Error:: #%d - %s\n", elwix_GetErrno(), elwix_GetError()); return 1; } else - printf("We parsed %d tokens\n", ret); + printf("We parsed %d tokens next=%lu\n", ret, json->h_next); memset(toks, 0, sizeof toks); json_init(json, 1); ret = json_parse(json, teststr, strlen(teststr), toks, sizeof toks/sizeof *toks); @@ -45,7 +45,7 @@ run_simple(json_t *json) printf("Error:: #%d - %s\n", elwix_GetErrno(), elwix_GetError()); return 1; } else - printf("(strict) We parsed %d tokens\n", ret); + printf("(strict) We parsed %d tokens next=%lu\n", ret, json->h_next); if (!(tok = json_findbykey(teststr, "boza s kosmi", toks, ret))) printf("Key=\"boza s kosmi\" not found!\n");