]> granicus.if.org Git - python/commit
bpo-37834: Normalise handling of reparse points on Windows (GH-15370)
authorSteve Dower <steve.dower@python.org>
Wed, 21 Aug 2019 22:52:42 +0000 (15:52 -0700)
committerGitHub <noreply@github.com>
Wed, 21 Aug 2019 22:52:42 +0000 (15:52 -0700)
commit9eb3d5463976068900e94b860ced7e035885835c
treec97aa41b153e67db42ef4b13a9e20bc0747301f9
parentc30c869e8dec5eefdee7977943ffa11a8e3c8d75
bpo-37834: Normalise handling of reparse points on Windows (GH-15370)

bpo-37834: Normalise handling of reparse points on Windows
* ntpath.realpath() and nt.stat() will traverse all supported reparse points (previously was mixed)
* nt.lstat() will let the OS traverse reparse points that are not name surrogates (previously would not traverse any reparse point)
* nt.[l]stat() will only set S_IFLNK for symlinks (previous behaviour)
* nt.readlink() will read destinations for symlinks and junction points only

bpo-1311: os.path.exists('nul') now returns True on Windows
* nt.stat('nul').st_mode is now S_IFCHR (previously was an error)
16 files changed:
Doc/library/os.rst
Doc/library/shutil.rst
Doc/library/stat.rst
Doc/whatsnew/3.8.rst
Include/fileutils.h
Lib/shutil.py
Lib/test/test_os.py
Lib/test/test_shutil.py
Lib/test/test_tools/test_lll.py
Lib/test/test_venv.py
Misc/NEWS.d/next/Windows/2019-08-12-12-00-24.bpo-37834.VB2QVj.rst [new file with mode: 0644]
Misc/NEWS.d/next/Windows/2019-08-21-12-58-18.bpo-1311.BoW1wU.rst [new file with mode: 0644]
Modules/_stat.c
Modules/clinic/posixmodule.c.h
Modules/posixmodule.c
Python/fileutils.c