qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PULL 13/21] monitor: Inline monitor_has_error() into its o


From: Markus Armbruster
Subject: [Qemu-devel] [PULL 13/21] monitor: Inline monitor_has_error() into its only caller
Date: Tue, 2 Jun 2015 10:23:51 +0200

Signed-off-by: Markus Armbruster <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Luiz Capitulino <address@hidden>
---
 monitor.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/monitor.c b/monitor.c
index 56564d5..91f8a4e 100644
--- a/monitor.c
+++ b/monitor.c
@@ -377,11 +377,6 @@ static int GCC_FMT_ATTR(2, 3) monitor_fprintf(FILE *stream,
     return 0;
 }
 
-static inline int monitor_has_error(const Monitor *mon)
-{
-    return mon->error != NULL;
-}
-
 static void monitor_json_emitter(Monitor *mon, const QObject *data)
 {
     QString *json;
@@ -5031,7 +5026,7 @@ static void handle_qmp_command(JSONMessageParser *parser, 
QList *tokens)
 
     if (cmd->mhandler.cmd_new(mon, args, &data)) {
         /* Command failed... */
-        if (!monitor_has_error(mon)) {
+        if (!mon->error) {
             /* ... without setting an error, so make one up */
             qerror_report(QERR_UNDEFINED_ERROR);
         }
-- 
1.9.3




reply via email to

[Prev in Thread] Current Thread [Next in Thread]