address review comments
This commit is contained in:
parent
553a9036eb
commit
a30b07dd36
@ -2706,7 +2706,7 @@
|
||||
],
|
||||
"clang" : [
|
||||
{
|
||||
"versions": "9.0:12.99",
|
||||
"versions": "9.0:12.0",
|
||||
"flags" : "-march=armv8.4-a"
|
||||
},
|
||||
{
|
||||
|
@ -468,6 +468,18 @@ def from_dict(base_path, d):
|
||||
|
||||
@property
|
||||
def _current_root(self):
|
||||
"""
|
||||
Return the directory in which the view is currently implemented.
|
||||
|
||||
If the view is using renameat2 for atomic updates, self.root is a directory and the root
|
||||
of the underlying implementation is the same as self.root.
|
||||
|
||||
If the view us using symlinks for atomic updates, self.root is a link and we read the link
|
||||
to find the root of the underlying implementation of the view.
|
||||
|
||||
If self.root does not exist or is a regular file, there is no current implementation of the
|
||||
view on the filesystem.
|
||||
"""
|
||||
if not os.path.islink(self.root):
|
||||
if os.path.isdir(self.root):
|
||||
return self.root
|
||||
|
@ -19,7 +19,7 @@
|
||||
# python links against libc, so we can treat this as a libc handle
|
||||
# we could also use CDLL("libc.so.6") but this is (irrelevantly) more future proof
|
||||
libc = ctypes.CDLL(None)
|
||||
except BaseException:
|
||||
except OSError:
|
||||
pass
|
||||
|
||||
renameat2 = getattr(libc, "renameat2", None)
|
||||
|
Loading…
Reference in New Issue
Block a user