This can be triggered when jsondump.c gets changed a little, namely
tokcount = tokcount * 2;
at line 112 must be changed to
tokcount++;
I am using jsmn_parse(&p, js, NULL, 0); to get the number of tokens i need to allocate, when i add one more token it doesn't crash but believes [3,4] is a object key and the value isn't tokenised.
Doesn't matter if strict mode or parent links are enabled.
The following input results in a overflow
This can be triggered when jsondump.c gets changed a little, namely
at line 112 must be changed to
I am using
jsmn_parse(&p, js, NULL, 0);
to get the number of tokens i need to allocate, when i add one more token it doesn't crash but believes [3,4] is a object key and the value isn't tokenised.Doesn't matter if strict mode or parent links are enabled.