mklni: Fix unsafe remove_chroot
This commit is contained in:
parent
6c4d6008e3
commit
22be3bc759
7
mklni
7
mklni
|
@ -281,8 +281,13 @@ remove_chroot()
|
||||||
log "Failed to umount chroot" error
|
log "Failed to umount chroot" error
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
{
|
||||||
|
rm -rf "${CHROOTDIR:?}/" &&
|
||||||
log "Done!"
|
log "Done!"
|
||||||
rm -rf "${CHROOTDIR:?}/"
|
} || {
|
||||||
|
log "Failed to remove chroot" error
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
chroot_into()
|
chroot_into()
|
||||||
|
|
Loading…
Reference in a new issue