Merge pull request #1239 from tofbouf/patch-1

Apply realpath to find mounted points to unmount
This commit is contained in:
Alexandre Aubin 2021-06-07 23:41:08 +02:00 committed by GitHub
commit 8e19eabe16
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2658,7 +2658,7 @@ def _recursive_umount(directory):
points_to_umount = [ points_to_umount = [
line.split(" ")[2] line.split(" ")[2]
for line in mount_lines for line in mount_lines
if len(line) >= 3 and line.split(" ")[2].startswith(directory) if len(line) >= 3 and line.split(" ")[2].startswith(os.path.realpath(directory))
] ]
everything_went_fine = True everything_went_fine = True