]> Git Repo - qemu.git/commitdiff
info qdm: do not require a parent_bus to be set
authorAnthony Liguori <[email protected]>
Fri, 23 Dec 2011 14:16:58 +0000 (08:16 -0600)
committerAnthony Liguori <[email protected]>
Fri, 3 Feb 2012 16:41:08 +0000 (10:41 -0600)
Signed-off-by: Anthony Liguori <[email protected]>
hw/qdev-monitor.c

index a6f0e163970648e0dbd1480a2e2aec07b0109980..56a34587b8c7121a26ac837d3cdbda198f8ea874 100644 (file)
@@ -163,12 +163,14 @@ int qdev_device_help(QemuOpts *opts)
         error_printf("%s.%s=%s\n", driver, prop->name,
                      prop->info->legacy_name ?: prop->info->name);
     }
-    for (prop = info->bus_info->props; prop && prop->name; prop++) {
-        if (!prop->info->parse) {
-            continue;           /* no way to set it, don't show */
+    if (info->bus_info) {
+        for (prop = info->bus_info->props; prop && prop->name; prop++) {
+            if (!prop->info->parse) {
+                continue;           /* no way to set it, don't show */
+            }
+            error_printf("%s.%s=%s\n", driver, prop->name,
+                         prop->info->legacy_name ?: prop->info->name);
         }
-        error_printf("%s.%s=%s\n", driver, prop->name,
-                     prop->info->legacy_name ?: prop->info->name);
     }
     return 1;
 }
This page took 0.026049 seconds and 4 git commands to generate.