mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 09:13:55 -06:00
qapi: Separate type QNull from QObject
Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
parent
df95f1a298
commit
006ca09f30
7 changed files with 28 additions and 22 deletions
|
@ -445,7 +445,7 @@ static QObject *parse_keyword(JSONParserContext *ctxt)
|
|||
} else if (!strcmp(token->str, "false")) {
|
||||
return QOBJECT(qbool_from_bool(false));
|
||||
} else if (!strcmp(token->str, "null")) {
|
||||
return qnull();
|
||||
return QOBJECT(qnull());
|
||||
}
|
||||
parse_error(ctxt, token, "invalid keyword '%s'", token->str);
|
||||
return NULL;
|
||||
|
|
|
@ -14,7 +14,9 @@
|
|||
#include "qemu-common.h"
|
||||
#include "qapi/qmp/qobject.h"
|
||||
|
||||
QObject qnull_ = {
|
||||
.type = QTYPE_QNULL,
|
||||
.refcnt = 1,
|
||||
QNull qnull_ = {
|
||||
.base = {
|
||||
.type = QTYPE_QNULL,
|
||||
.refcnt = 1,
|
||||
},
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue