Commit cad09330 authored by Brett Cannon's avatar Brett Cannon

Don't leave around a test symlink file.

parent b44824b3
...@@ -1465,9 +1465,11 @@ def can_symlink(): ...@@ -1465,9 +1465,11 @@ def can_symlink():
global _can_symlink global _can_symlink
if _can_symlink is not None: if _can_symlink is not None:
return _can_symlink return _can_symlink
symlink_path = TESTFN + "can_symlink"
try: try:
os.symlink(TESTFN, TESTFN + "can_symlink") os.symlink(TESTFN, symlink_path)
can = True can = True
os.remove(symlink_path)
except (OSError, NotImplementedError): except (OSError, NotImplementedError):
can = False can = False
_can_symlink = can _can_symlink = can
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment