diff options
Diffstat (limited to 'Lib/shutil.py')
| -rw-r--r-- | Lib/shutil.py | 5 | 
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/shutil.py b/Lib/shutil.py index d361fa2..43726b4 100644 --- a/Lib/shutil.py +++ b/Lib/shutil.py @@ -27,7 +27,10 @@ def copyfileobj(fsrc, fdst, length=16*1024):  def _samefile(src, dst):      # Macintosh, Unix.      if hasattr(os.path,'samefile'): -        return os.path.samefile(src, dst) +        try: +            return os.path.samefile(src, dst) +        except OSError: +            return False      # All other platforms: check for same pathname.      return (os.path.normcase(os.path.abspath(src)) ==  | 
