mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-23 06:05:27 +00:00
storage: Add check for different ports for host duplicate matching
In virStoragePoolSourceMatchSingleHost, add a comparison for port number being different prior to checking the 'name' field.
This commit is contained in:
parent
9aced8c9d5
commit
401623bcb4
@ -2412,6 +2412,9 @@ virStoragePoolSourceMatchSingleHost(virStoragePoolSourcePtr poolsrc,
|
||||
if (poolsrc->nhost != 1 && defsrc->nhost != 1)
|
||||
return false;
|
||||
|
||||
if (poolsrc->hosts[0].port != defsrc->hosts[0].port)
|
||||
return false;
|
||||
|
||||
return STREQ(poolsrc->hosts[0].name, defsrc->hosts[0].name);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user