parameters: (path)
return_statement: return False
docstring: Test whether a path is a mount point
docstring_summary: Test whether a path is a mount point
docstring_tokens: Test whether a path is a mount point
function: def ismount(path):
      """Test whether a path is a mount point"""
      try:
          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
      dev2 = s2.st_dev
      if dev1 != dev2:
          return True     # path/.. on a different device as path
      ino1 = s1.st_ino
      ino2 = s2.st_ino
      if ino1 == ino2:
          return True     # path/.. is the same i-node as path
      return False
function_tokens: def ismount ( path ) : try : 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 dev2 = s2 . st_dev if dev1 != dev2 : return True # path/.. on a different device as path ino1 = s1 . st_ino ino2 = s2 . st_ino if ino1 == ino2 : return True # path/.. is the same i-node as path return False