Add -nodefconfig command line option to qemu.
authorDaniel Berrange <berrange@redhat.com>
Tue, 24 Aug 2010 13:27:15 +0000 (14:27 +0100)
committerRichard Jones <rjones@redhat.com>
Tue, 24 Aug 2010 13:27:15 +0000 (14:27 +0100)
Without this option, qemu will read some defaults from /etc/qemu/
configuration files.

src/launch.c

index 9262cc5..287cc40 100644 (file)
@@ -342,6 +342,9 @@ guestfs__launch (guestfs_h *g)
      */
     g->cmdline[0] = g->qemu;
 
      */
     g->cmdline[0] = g->qemu;
 
+    if (qemu_supports (g, "-nodefconfig"))
+      add_cmdline (g, "-nodefconfig");
+
     /* qemu sometimes needs this option to enable hardware
      * virtualization, but some versions of 'qemu-kvm' will use KVM
      * regardless (even where this option appears in the help text).
     /* qemu sometimes needs this option to enable hardware
      * virtualization, but some versions of 'qemu-kvm' will use KVM
      * regardless (even where this option appears in the help text).