From 284e760e5ae35f882c89541b35a28b16d7643c95 Mon Sep 17 00:00:00 2001 From: Vadim Troshchinskiy Date: Fri, 27 Sep 2024 12:46:12 +0200 Subject: [PATCH] Fix ticket #770: Re-parse filesystems list after mounting --- gitlib/gitlib.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gitlib/gitlib.py b/gitlib/gitlib.py index 205b856..84f5ab0 100755 --- a/gitlib/gitlib.py +++ b/gitlib/gitlib.py @@ -122,6 +122,7 @@ class NTFSLibrary: subprocess.run(["/usr/sbin/mkntfs", device, "-Q", "-L", label]) + def mount_filesystem(self, device, mountpoint): """ Mounts a filesystem on the specified mountpoint using the specified NTFS implementation. @@ -142,6 +143,11 @@ class NTFSLibrary: else: raise ValueError("Unknown NTFS implementation: {self.implementation}") + + # We've mounted a new filesystem, update our filesystems list + self.mounts = self._parse_mounts() + + def _hex_to_bin(self, hex_str): while len(hex_str) != 16: