mirror of
https://github.com/dockur/windows.git
synced 2026-08-04 04:57:13 +01:00
fix: Preserve installation ISO when marker creation fails (#1856)
This commit is contained in:
+12
-4
@@ -151,10 +151,18 @@ markWindowsBooted() {
|
|||||||
|
|
||||||
# Remove CD-ROM ISO after install
|
# Remove CD-ROM ISO after install
|
||||||
! ready && return 0
|
! ready && return 0
|
||||||
|
|
||||||
touch "$file"
|
if ! touch "$file"; then
|
||||||
! setOwner "$file" && error "Failed to set the owner for \"$file\" !"
|
error "Failed to create Windows installation marker!"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! setOwner "$file"; then
|
||||||
|
rm -f "$file"
|
||||||
|
error "Failed to set the owner for \"$file\" !"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
if ! disabled "$REMOVE"; then
|
if ! disabled "$REMOVE"; then
|
||||||
rm -f "$BOOT" 2>/dev/null || true
|
rm -f "$BOOT" 2>/dev/null || true
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user