mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-22 18:50:08 +03:00
Bug #4610: Check memory value in KB
(cherry picked from commit 1c3881c6c6e22c2d12656099fc22a528bc102070)
This commit is contained in:
parent
cbbfee3b65
commit
1d6e8e5be2
@ -473,7 +473,7 @@ int VirtualMachine::insert(SqlDB * db, string& error_str)
|
||||
// Check for CPU, VCPU and MEMORY attributes
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if ( user_obj_template->get("MEMORY", ivalue) == false || ivalue <= 0 )
|
||||
if ( user_obj_template->get("MEMORY", ivalue) == false || (ivalue * 1024) <= 0 )
|
||||
{
|
||||
goto error_memory;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user