mirror of
https://github.com/valitydev/salt.git
synced 2024-11-06 16:45:27 +00:00
Fix issue where safe_walk would skip files
This commit is contained in:
parent
1e9579826d
commit
6a1ad32904
@ -1050,10 +1050,10 @@ def safe_walk(dir_):
|
||||
if stat.S_ISLNK(mode):
|
||||
real = os.path.realpath(full)
|
||||
try:
|
||||
mode = os.stat(real).st_mode
|
||||
if stat.S_ISDIR(mode):
|
||||
if full.startswith(real):
|
||||
continue
|
||||
smode = os.stat(real).st_mode
|
||||
if stat.S_ISDIR(smode):
|
||||
if not full.startswith(real):
|
||||
mode = smode
|
||||
except os.error:
|
||||
pass
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user