mirror of
https://github.com/OpenNebula/one.git
synced 2026-11-19 03:12:55 +09:00
Bug #1694: Rollback cluster id when system DS is added to any cluster
This commit is contained in:
1 parent
e04b24c066
commit
1c826bced5
1 file changed
+12
@@ -149,6 +149,18 @@ void RequestManagerCluster::add_generic(
|
||||
request_error("Cannot add object to cluster", err_msg),
|
||||
att);
|
||||
|
||||
// Rollback
|
||||
get(object_id, true, &object, &cluster_obj);
|
||||
|
||||
if ( object != 0 )
|
||||
{
|
||||
cluster_obj->set_cluster(old_cluster_id, old_cluster_name);
|
||||
|
||||
pool->update(object);
|
||||
|
||||
object->unlock();
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user