qemuAssignDeviceInputAlias: Be tolerant to pre-existent alias

https://bugzilla.redhat.com/show_bug.cgi?id=1554876

This is missing in 6bc4a371cf and therefore we are effectively
overwriting user provided aliases for <input/> devices.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Michal Privoznik 2018-03-13 13:01:11 +01:00
parent dc567cc22b
commit a02a52751f

View File

@ -513,6 +513,9 @@ qemuAssignDeviceInputAlias(virDomainDefPtr def,
virDomainInputDefPtr input,
int idx)
{
if (input->info.alias)
return 0;
if (idx == -1) {
int thisidx;
size_t i;