In some situations I need to parse an http response having application/json as Content-Type that contains only a quoted string. Here is an example of the raw http response:
Using the new CkJsonObject I am able to Load() the string "4.22.0007", but cannot extract the unquoted string.
I know that this response is non-standard and I could simply remove the quotes manually, since there is anyhow nothing else to be done here. However shouldn't the Load() method fail due to invalid Json ?
In Jansson's Json C library they added an option (JSON_DECODE_ANY) to ignore RFC 4627 and allow loading non-object and non-array single values directly. I am not saying that this is a good workaround though.
asked Mar 15 '16 at 10:25