mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
qemu: Avoid useless tmp variable in qemuCanonicalizeMachine
Signed-off-by: Jiri Denemark <jdenemar@redhat.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
This commit is contained in:
parent
5904676d2f
commit
b0aa9d31f2
@ -947,10 +947,8 @@ qemuCanonicalizeMachine(virDomainDef *def, virQEMUCaps *qemuCaps)
|
||||
return 0;
|
||||
|
||||
if (STRNEQ(canon, def->os.machine)) {
|
||||
char *tmp;
|
||||
tmp = g_strdup(canon);
|
||||
VIR_FREE(def->os.machine);
|
||||
def->os.machine = tmp;
|
||||
def->os.machine = g_strdup(canon);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user