We have a special function for assigning aliases to RNG devices.
Use that instead of plain virAsprintf().
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
src/qemu/qemu_alias.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/qemu/qemu_alias.c b/src/qemu/qemu_alias.c
index 72df1083f..eca1dc64c 100644
--- a/src/qemu/qemu_alias.c
+++ b/src/qemu/qemu_alias.c
@@ -501,7 +501,7 @@ qemuAssignDeviceAliases(virDomainDefPtr def, virQEMUCapsPtr qemuCaps)
return -1;
}
for (i = 0; i < def->nrngs; i++) {
- if (virAsprintf(&def->rngs[i]->info.alias, "rng%zu", i) <
0)
+ if (qemuAssignDeviceRNGAlias(def, def->rngs[i]) < 0)
return -1;
}
if (def->tpm) {
--
2.13.6