You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildstream.apache.org by gi...@apache.org on 2020/12/29 13:10:40 UTC
[buildstream] 21/21: Rearrange comment
This is an automated email from the ASF dual-hosted git repository.
github-bot pushed a commit to branch jmac/cas_to_cas_oct
in repository https://gitbox.apache.org/repos/asf/buildstream.git
commit 711c98472e024028e9392a791c850fc9ee326ede
Author: Jim MacArthur <ji...@codethink.co.uk>
AuthorDate: Fri Oct 26 14:11:37 2018 +0100
Rearrange comment
---
buildstream/storage/_casbaseddirectory.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/buildstream/storage/_casbaseddirectory.py b/buildstream/storage/_casbaseddirectory.py
index a99b486..53fdb03 100644
--- a/buildstream/storage/_casbaseddirectory.py
+++ b/buildstream/storage/_casbaseddirectory.py
@@ -399,11 +399,11 @@ class CasBasedDirectory(Directory):
if c == ".":
pass
elif c == "..":
+ if directory.parent is not None:
+ directory = directory.parent
# If directory.parent *is* None, this is an attempt to access
# '..' from the root, which is valid under POSIX; it just
# returns the root.
- if directory.parent is not None:
- directory = directory.parent
else:
if c in directory.index:
f = directory._resolve(c, absolute_symlinks_resolve, first_seen_object=first_seen_object)