Skip to content

Commit dacf074

Browse files
committed
vm(qemu): do not try to eject drives on non-disk interfaces
Fixes #5845
1 parent 917f357 commit dacf074

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Services/UTMQemuVirtualMachine.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -748,7 +748,7 @@ extension UTMQemuVirtualMachine {
748748
// an image bookmark was saved while QEMU was NOT running
749749
let url = try URL(resolvingPersistentBookmarkData: localBookmark)
750750
try await changeMedium(drive, to: url, isAccessOnly: !isMounting)
751-
} else if isMounting {
751+
} else if isMounting && (drive.imageType == .cd || drive.imageType == .disk) {
752752
// a placeholder image might have been mounted
753753
try await eject(drive)
754754
}

0 commit comments

Comments
 (0)