--- a/src/json.c Tue Oct 22 12:16:16 2024 +0200 +++ b/src/json.c Tue Oct 22 12:17:48 2024 +0200 @@ -510,9 +510,9 @@ // expect ':' if (token.tokentype != CX_JSON_TOKEN_NAME_SEPARATOR) return -1; // next state - p->states[p->nstates] = 1; + p->states[p->nstates] = JP_STATE_VALUE_BEGIN_OBJ; ret = json_read(p); - } else if (state == 7) { + } else if (state == JP_STATE_OBJ_SEP_OR_CLOSE) { // expect ',' or '}' if (token.tokentype == CX_JSON_TOKEN_VALUE_SEPARATOR) { p->states[p->nstates] = JP_STATE_OBJ_NAME;