Skip to content

Commit

Permalink
Fix CopyFile2 check
Browse files Browse the repository at this point in the history
  • Loading branch information
barneygale committed Aug 4, 2024
1 parent a51ce63 commit 51b1e6d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Lib/pathlib/_os.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def copyfd(source_fd, target_fd):
copyfd = None


if _winapi:
if _winapi and hasattr(_winapi, 'CopyFile2'):
def copyfile(source, target):
"""
Copy from one file to another using CopyFile2 (Windows only).
Expand Down

0 comments on commit 51b1e6d

Please sign in to comment.