]> granicus.if.org Git - python/commitdiff
Bug #1713: posixpath.ismount() claims symlink to a mountpoint is a mountpoint.
authorChristian Heimes <christian@cheimes.de>
Fri, 4 Jan 2008 13:22:36 +0000 (13:22 +0000)
committerChristian Heimes <christian@cheimes.de>
Fri, 4 Jan 2008 13:22:36 +0000 (13:22 +0000)
Lib/posixpath.py
Misc/NEWS

index b396f0ace5ec635e1c45ed40b28fe5272c6957f5..515b0ae0d0b99bc2ab5ee73c726472bfe6cff9d4 100644 (file)
@@ -245,8 +245,8 @@ def samestat(s1, s2):
 def ismount(path):
     """Test whether a path is a mount point"""
     try:
-        s1 = os.stat(path)
-        s2 = os.stat(join(path, '..'))
+        s1 = os.lstat(path)
+        s2 = os.lstat(join(path, '..'))
     except os.error:
         return False # It doesn't exist -- so not a mount point :-)
     dev1 = s1.st_dev
index 67af91e80284bf50fca86152cb7fe30496320922..167bedc5d44e2f7a2c7cef96493d581a803be15b 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -53,6 +53,8 @@ Core and builtins
 Library
 -------
 
+- Bug #1713: posixpath.ismount() claims symlink to a mountpoint is a mountpoint.
+
 - Issue #1700: Regular expression inline flags incorrectly handle certain
   unicode characters.