Re: [REPOST PATCH v6 4/8] qemu: Refactor qemuBuildSCSIiSCSIHostdevDrvStr slightly

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

 



On Wed, Nov 08, 2017 at 08:15:57 -0500, John Ferlan wrote:
> Rather than building the "file" string in qemuBuildSCSIHostdevDrvStr
> build it in the called helper.
> 
> Signed-off-by: John Ferlan <jferlan@xxxxxxxxxx>
> ---
>  src/qemu/qemu_command.c | 13 ++++++++++---
>  1 file changed, 10 insertions(+), 3 deletions(-)

[...]

> @@ -4956,7 +4963,7 @@ qemuBuildSCSIHostdevDrvStr(virDomainHostdevDefPtr dev)
>      if (scsisrc->protocol == VIR_DOMAIN_HOSTDEV_SCSI_PROTOCOL_TYPE_ISCSI) {
>          if (!(source = qemuBuildSCSIiSCSIHostdevDrvStr(dev)))
>              goto error;
> -        virBufferAsprintf(&buf, "file=%s,if=none,format=raw", source);
> +        virBufferAsprintf(&buf, "%s", source);

You should use 'virBufferAdd' since this is not doing any formatting.

ACK

Attachment: signature.asc
Description: PGP signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]
  Powered by Linux