mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-23 13:05:27 +00:00
qemu: domain: Clear startup policy for dropped removable media
When a source image is dropped when missing due to startup policy the policy needs to be cleared since it was relevant only for the given storage source. New sources need to update it if needed.
This commit is contained in:
parent
2692304c94
commit
6e19cc59a6
@ -4341,6 +4341,8 @@ qemuDomainCheckRemoveOptionalDisk(virQEMUDriverPtr driver,
|
||||
disk->info.alias,
|
||||
VIR_DOMAIN_EVENT_DISK_CHANGE_MISSING_ON_START);
|
||||
ignore_value(virDomainDiskSetSource(disk, NULL));
|
||||
/* keeping the old startup policy would be invalid for new images */
|
||||
disk->startupPolicy = VIR_DOMAIN_STARTUP_POLICY_DEFAULT;
|
||||
} else {
|
||||
event = virDomainEventDiskChangeNewFromObj(vm, src, NULL,
|
||||
disk->info.alias,
|
||||
|
Loading…
x
Reference in New Issue
Block a user