Revert "Fix a glaring error in the logic backport of posixpath."

This reverts commit b357f2bca3, which was
never meant to go into 3.10.
This commit is contained in:
Thomas Wouters 2025-06-03 14:25:37 +02:00
parent b357f2bca3
commit e0cb9afea4

View file

@ -429,7 +429,9 @@ def _joinrealpath(path, rest, strict, seen):
newpath = join(path, name)
try:
st = os.lstat(newpath)
except ignored_error:
except OSError:
if strict:
raise
is_link = False
else:
is_link = stat.S_ISLNK(st.st_mode)