vm.delete() must not remove unpluggable VDIs.

This commit is contained in:
Julien Fontanet 2015-06-18 16:11:08 +02:00
parent 123677b6c6
commit e7b3e28f76

View File

@ -567,6 +567,11 @@ export default class Xapi extends XapiBase {
if (deleteDisks) {
await Promise.all(map(vm.$VBDs, vbd => {
// Do not delete unpluggable VDIs.
if (vbd.unpluggable) {
return
}
try {
return this._deleteVdi(vbd.$VDI).catch(noop)
} catch (_) {}