Statistics
| Branch: | Revision:

root / qjson.c @ bd023f95

History | View | Annotate | Download (6.2 kB)

# Date Author Comment
bd032695 06/11/2010 09:25 pm Luiz Capitulino

qjson: Handle "\f"

It's valid JSON and should be handled.

Signed-off-by: Luiz Capitulino <>

668e3cac 02/10/2010 09:46 pm Luiz Capitulino

qjson: Improve debugging

Add an assert() to qobject_from_jsonf() to assure that the returned
QObject is not NULL. Currently this is duplicated in the callers.

Signed-off-by: Luiz Capitulino <>
Signed-off-by: Anthony Liguori <>

ff06ea21 01/26/2010 10:54 pm Anthony Liguori

json: escape u0000 .. u001F when outputting json

Markus Armbruster pointed out:

JSON requires control characters in strings to be escaped. RFC 4627
section 2.5:

A string begins and ends with quotation marks.  All Unicode
characters may be placed within the quotation marks except for the...
9f9daf9a 12/03/2009 05:41 pm Luiz Capitulino

Introduce QError

QError is a high-level data type which represents an exception
in QEMU, it stores the following error information:

- class Error class name (eg. "ServiceUnavailable")
- description A detailed error description, which can contain...

8ff5a7d3 12/03/2009 05:41 pm Luiz Capitulino

QJSON: Introduce qobject_from_jsonv()

It accepts a va_list and will be used by QError. Also simplifies
the code a little, as the other qobject_from_() functions can
use it.

Signed-off-by: Luiz Capitulino <>
Signed-off-by: Anthony Liguori <>

1fd825f7 11/17/2009 04:49 pm Anthony Liguori

Provide marshalling mechanism for json

This introduces qobject_to_json which will convert a QObject to a JSON string
representation.

Signed-off-by: Anthony Liguori <>

b4748b9b 11/17/2009 04:49 pm Anthony Liguori

Add a QObject JSON wrapper

This provides a QObject interface for creating QObjects from a JSON expression.

Signed-off-by: Anthony Liguori <>