Patch #941486: add os.path.lexists(). Also fix bug #940578 by using lexists in glob.glob.
diff --git a/Lib/ntpath.py b/Lib/ntpath.py
index 1f355ec..649e424 100644
--- a/Lib/ntpath.py
+++ b/Lib/ntpath.py
@@ -249,7 +249,6 @@
# Does a path exist?
-# This is false for dangling symbolic links.
def exists(path):
"""Test whether a path exists"""
@@ -259,6 +258,8 @@
return False
return True
+lexists = exists
+
# Is a path a dos directory?
# This follows symbolic links, so both islink() and isdir() can be true