Skip to content

Commit

Permalink
Improving robustness of fromiso cleanup process with is_mountpoint (C…
Browse files Browse the repository at this point in the history
…loses: #668100).
  • Loading branch information
Tails developers authored and daniel-baumann committed Jun 4, 2012
1 parent 204da27 commit fdfb568
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions scripts/live
Expand Up @@ -1595,8 +1595,14 @@ mountroot ()
# rid of it when running from RAM
if [ -n "$FROMISO" ] && [ "${TORAM}" ]
then
losetup -d /dev/loop0
grep -q /live/fromiso /proc/mounts && umount /live/fromiso
losetup -d /dev/loop0

if is_mountpoint /live/fromiso
then
umount /live/fromiso
rmdir --ignore-fail-on-non-empty /live/fromiso \
>/dev/null 2>&1 || true
fi
fi

if [ -n "${MODULETORAMFILE}" ] || [ -n "${PLAIN_ROOT}" ]
Expand Down

0 comments on commit fdfb568

Please sign in to comment.