mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-27 10:50:10 +03:00
Bug #1363: Make VCPU optional again
This commit is contained in:
parent
65ec7517cc
commit
fc08d847f2
@ -257,6 +257,10 @@ int VirtualMachine::insert(SqlDB * db, string& error_str)
|
||||
goto error_cpu;
|
||||
}
|
||||
|
||||
// VCPU is optional, first check if the attribute exists, then check it is
|
||||
// an integer
|
||||
get_template_attribute("VCPU", value);
|
||||
|
||||
if ( value.empty() == false )
|
||||
{
|
||||
if ( get_template_attribute("VCPU", ivalue) == false || ivalue <= 0 )
|
||||
|
Loading…
x
Reference in New Issue
Block a user