mirror of
https://github.com/OpenNebula/one.git
synced 2025-01-20 14:03:36 +03:00
B #6692: Check VMGroupRole in Inter-role Anti-affinity rules
Add a check before dereferencing the group roles pointer. (cherry picked from commit 48bab98a255eb9b335a18f21151b67747682fa00)
This commit is contained in:
parent
34ccd7261b
commit
1607b4a014
@ -176,6 +176,11 @@ void VMGroupXML::set_antiaffinity_requirements(VirtualMachinePoolXML * vmpool,
|
||||
|
||||
VMGroupRole * r = roles.get(i);
|
||||
|
||||
if ( r == 0 )
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
const std::set<int>& vms = r->get_vms();
|
||||
|
||||
for ( auto vm_id : vms )
|
||||
|
Loading…
x
Reference in New Issue
Block a user