On 11/08/2010 11:07 AM, Cole Robinson wrote: > static int qemudDomainChangeEjectableMedia(struct qemud_driver *driver, > virDomainObjPtr vm, > virDomainDiskDefPtr disk, > - unsigned long long qemuCmdFlags) > + unsigned long long qemuCmdFlags, > + bool force) Since this is bool... > @@ -8719,7 +8720,8 @@ static int qemudDomainAttachDevice(virDomainPtr dom, > case VIR_DOMAIN_DISK_DEVICE_FLOPPY: > ret = qemudDomainChangeEjectableMedia(driver, vm, > dev->data.disk, > - qemuCmdFlags); > + qemuCmdFlags, > + 0); ...this should be false, not 0... > @@ -8964,7 +8967,8 @@ static int qemuDomainUpdateDeviceFlags(virDomainPtr dom, > case VIR_DOMAIN_DISK_DEVICE_FLOPPY: > ret = qemudDomainChangeEjectableMedia(driver, vm, > dev->data.disk, > - qemuCmdFlags); > + qemuCmdFlags, > + flags & VIR_DOMAIN_DEVICE_EJECT_FORCE); ...and, per the limitations of gnulib's <stdbool.h> replacement on C89 compilers, this must be (flags & VIR_DOMAIN_DEVICE_EJECT_FORCE) != 0, since you can't rely on the compiler auto-converting non-zero to true. -- Eric Blake eblake@xxxxxxxxxx +1-801-349-2682 Libvirt virtualization library http://libvirt.org
Attachment:
signature.asc
Description: OpenPGP digital signature
-- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list