mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-22 18:50:08 +03:00
Feature #602: onevnet release returns error if a Lease is not used, this achieves the same behaviour for fixed and ranged networks
This commit is contained in:
parent
ee6888567a
commit
a173e7bd75
@ -490,7 +490,7 @@ int Leases::free_leases(vector<const Attribute*>& vector_leases,
|
||||
|
||||
it = leases.find(i_ip);
|
||||
|
||||
if ( it == leases.end() || (it->second->used && it->second->vid != -1) )
|
||||
if ( it == leases.end() || !it->second->used || it->second->vid != -1 )
|
||||
{
|
||||
error_msg = "Lease is not on hold.";
|
||||
return -1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user