diff options
Diffstat (limited to 'Doc/library/shutil.rst')
-rw-r--r-- | Doc/library/shutil.rst | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/Doc/library/shutil.rst b/Doc/library/shutil.rst index 5d3f881..34d8a63 100644 --- a/Doc/library/shutil.rst +++ b/Doc/library/shutil.rst @@ -393,11 +393,10 @@ provided by this module. :: errors.extend(err.args[0]) try: copystat(src, dst) - except WindowsError: - # can't copy file access times on Windows - pass except OSError as why: - errors.extend((src, dst, str(why))) + # can't copy file access times on Windows + if why.winerror is None: + errors.extend((src, dst, str(why))) if errors: raise Error(errors) |