Skip to content

Commit

Permalink
Update package
Browse files Browse the repository at this point in the history
  • Loading branch information
Eeems authored Dec 17, 2024
1 parent e5dbd9a commit 00b66de
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions package/debian-chroot/package
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,13 @@ debian-chroot() {
}
preremove() {
source /home/root/.config/debian-chroot.conf
if lsof "$chroot_path"; then
if lsof "$chroot_path" 2>/dev/null | grep "$chroot_path"; then
echo "Error: debian-chroot has running processes"
exit 1
fi
umount -R "$chroot_path"
if grep -q "$chroot_path " /proc/mounts; then
/bin/umount -R "$chroot_path"
fi
}
postremove() {
source /home/root/.config/debian-chroot.conf
Expand Down

0 comments on commit 00b66de

Please sign in to comment.