(pathname, dir_fd)
| 206 | |
| 207 | |
| 208 | def _lexists(pathname, dir_fd): |
| 209 | # Same as os.path.lexists(), but with dir_fd |
| 210 | if dir_fd is None: |
| 211 | return os.path.lexists(pathname) |
| 212 | try: |
| 213 | os.lstat(pathname, dir_fd=dir_fd) |
| 214 | except (OSError, ValueError): |
| 215 | return False |
| 216 | else: |
| 217 | return True |
| 218 | |
| 219 | def _isdir(pathname, dir_fd): |
| 220 | # Same as os.path.isdir(), but with dir_fd |