mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 04:25:18 +00:00
qemu: remove unnecessary virBufferFreeAndReset() after virCommandAddArgBuffer()
The latter function is guaranteed to always clear out the virBuffer anyway, so this is redundant and could add to extra cargo-cult code if used as an example. Signed-off-by: Laine Stump <laine@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
f7e3610095
commit
d30cfe70ef
@ -9080,7 +9080,6 @@ qemuBuldDomainLoaderPflashCommandLine(virCommandPtr cmd,
|
||||
virCommandAddArgBuffer(cmd, &buf);
|
||||
|
||||
if (loader->nvram) {
|
||||
virBufferFreeAndReset(&buf);
|
||||
virBufferAddLit(&buf, "file=");
|
||||
virQEMUBuildBufferEscapeComma(&buf, loader->nvram);
|
||||
virBufferAsprintf(&buf, ",if=pflash,format=raw,unit=%d", unit);
|
||||
|
Loading…
x
Reference in New Issue
Block a user