1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-01-26 10:03:37 +03:00

B #5356: (vcenter) core crash on hold hotfix (#526)

(cherry picked from commit d6d266b5bf79b3ed237402c4f3d7d715515330ab)
This commit is contained in:
Sergio Semedi Barranco 2017-10-17 10:19:04 +02:00 committed by Ruben S. Montero
parent 6fb65843b2
commit 2953334157

View File

@ -235,7 +235,7 @@ void DispatchManager::free_vm_resources(VirtualMachine * vm)
VectorAttribute * graphics = vm->get_template_attribute("GRAPHICS");
if ( graphics != 0 && (graphics->vector_value("PORT", port) == 0))
if ( graphics != 0 && (graphics->vector_value("PORT", port) == 0) && vm->hasHistory())
{
graphics->remove("PORT");
clpool->release_vnc_port(vm->get_cid(), port);