server: Honor vm.destroy.forcestop when expunge a vm (#3965)

When expunge a Running vm, vm will be stopped with forcestop=false which does not make sense. we should honor vm.destroy.forcestop in global setting, or always set forcestop=true.
This commit is contained in:
Wei Zhou 2020-06-09 04:55:51 +02:00 committed by GitHub
parent fef4458830
commit 851534ac17
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -502,7 +502,7 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac
return;
}
advanceStop(vm.getUuid(), false);
advanceStop(vm.getUuid(), VmDestroyForcestop.value());
vm = _vmDao.findByUuid(vm.getUuid());
try {