On Friday, 17 August 2018 17:30:35 CEST Eric Blake wrote:
On 08/17/2018 10:16 AM, Richard W.M. Jones wrote:
Commit bd1c5c9f4dcf38458099db8a0bf4659a07ef055d changed all the code to use Jansson instead of yajl. However it didn't change the OCaml API name (which was still Yajl).
Are you aware that Jansson can't parse all JSON generated by qemu, and that the developers of Jansson did not seem sympathetic to patches that would make it possible? Libvirt recently reverted their use of Jansson because of its inability to deal with unsigned 64-bit numbers (and sadly, RFC7159 does not define bounds for what forms valid JSON numbers, but merely leaves it up to implementations to decide for themselves).
The problematic values that qemu outputs are, at least to my knowledge, only in the some of the messages in the QMP communication, which we do not do. We parse JSON from: - output of ldmtool - output of qemu-img - QMP schema - SimpleStream files Furthermore, why not just fix qemu, instead of letting its "JSON implementation" rule out perfectly compliant JSON parsers? -- Pino Toscano