json: Limit recursion depth
* src/cJSON.c (MAX_DEPTH): New. Maximum recursion depth. (parse_value, parse_array, parse_object): Carry and check depth argument. (cJSON_ParseWithOpts): Initialize depth.
This fixes a stack overflow if we get weird recursive
json data.
- GnuPG-Bug-Id: T4331