aboutsummaryrefslogtreecommitdiff
path: root/qapi/qmp-dispatch.c
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2015-01-13 16:16:35 +0100
committerMarkus Armbruster <armbru@redhat.com>2015-01-29 10:02:18 +0100
commita6c90cbccdc07d51d4bbff71d2680f1a2c287370 (patch)
tree91e766f466192c3e291bd7ebf77158e200b35eae /qapi/qmp-dispatch.c
parentbb5224edfb1e6f94aabaa8070d11c8f95f8ae277 (diff)
qmp: Eliminate silly QERR_COMMAND_NOT_FOUND macro
The QERR_ macros are leftovers from the days of "rich" error objects. They're used with error_set() and qerror_report(), and expand into the first *two* arguments. This trickiness has become pointless. Clean this one up. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'qapi/qmp-dispatch.c')
-rw-r--r--qapi/qmp-dispatch.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/qapi/qmp-dispatch.c b/qapi/qmp-dispatch.c
index 168b083c87..222742013f 100644
--- a/qapi/qmp-dispatch.c
+++ b/qapi/qmp-dispatch.c
@@ -76,7 +76,8 @@ static QObject *do_qmp_dispatch(QObject *request, Error **errp)
command = qdict_get_str(dict, "execute");
cmd = qmp_find_command(command);
if (cmd == NULL) {
- error_set(errp, QERR_COMMAND_NOT_FOUND, command);
+ error_set(errp, ERROR_CLASS_COMMAND_NOT_FOUND,
+ "The command %s has not been found", command);
return NULL;
}
if (!cmd->enabled) {