mirror of
https://github.com/9001/copyparty.git
synced 2025-08-18 09:22:31 -06:00
dodge a bullet on centos7
This commit is contained in:
parent
19f23c686e
commit
a362ee2246
|
@ -1034,11 +1034,13 @@ def sendfile_kern(lower, upper, f, s):
|
||||||
|
|
||||||
|
|
||||||
def statdir(logger, scandir, lstat, top):
|
def statdir(logger, scandir, lstat, top):
|
||||||
|
if lstat and not os.supports_follow_symlinks:
|
||||||
|
scandir = False
|
||||||
|
|
||||||
try:
|
try:
|
||||||
btop = fsenc(top)
|
btop = fsenc(top)
|
||||||
if scandir and hasattr(os, "scandir"):
|
if scandir and hasattr(os, "scandir"):
|
||||||
src = "scandir"
|
src = "scandir"
|
||||||
lstat = lstat and os.supports_follow_symlinks
|
|
||||||
with os.scandir(btop) as dh:
|
with os.scandir(btop) as dh:
|
||||||
for fh in dh:
|
for fh in dh:
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in a new issue