qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PATCH 3/9] vl: Fail right after first bad -object


From: Markus Armbruster
Subject: [Qemu-devel] [PATCH 3/9] vl: Fail right after first bad -object
Date: Thu, 28 May 2015 14:21:29 +0200

Failure to create a -object is a fatal error.  However, we delay the
actual exit until all -object are processed.  On the one hand, this
permits detection of genuine additional errors.  On the other hand, it
can muddy the waters with uninteresting additional errors, e.g. when a
later -object tries to reference a prior one that failed.

We generally stop right on the first bad option, so do that for
-object as well.

Signed-off-by: Markus Armbruster <address@hidden>
---
 vl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/vl.c b/vl.c
index a31e7a5..1553c9e 100644
--- a/vl.c
+++ b/vl.c
@@ -4050,7 +4050,7 @@ int main(int argc, char **argv, char **envp)
     }
 
     if (qemu_opts_foreach(qemu_find_opts("object"),
-                          object_create, NULL, 0) != 0) {
+                          object_create, NULL, 1) != 0) {
         exit(1);
     }
 
-- 
1.9.3




reply via email to

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