diff --git a/Lib/shutil.py b/Lib/shutil.py index baedd4cd962..14baa71e83a 100644 --- a/Lib/shutil.py +++ b/Lib/shutil.py @@ -124,6 +124,10 @@ def copytree(src, dst, symlinks=False): # XXX What about devices, sockets etc.? except (IOError, os.error), why: errors.append((srcname, dstname, why)) + # catch the Error from the recursive copytree so that we can + # continue with other files + except Error, err: + errors.extend(err.args[0]) copystat(src, dst) if errors: raise Error, errors