diff options
author | Georg Brandl <georg@python.org> | 2005-08-31 22:48:48 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2005-08-31 22:48:48 (GMT) |
commit | 3078cb922481646cf35cc31b5e4a358766092af8 (patch) | |
tree | 3e41505c2d2377fee4815598bd504352c46f3ca0 /Lib | |
parent | 6b4a932a971d0d2c3969b9d53ad574dfd39d2a44 (diff) | |
download | cpython-3078cb922481646cf35cc31b5e4a358766092af8.zip cpython-3078cb922481646cf35cc31b5e4a358766092af8.tar.gz cpython-3078cb922481646cf35cc31b5e4a358766092af8.tar.bz2 |
patch [ 1242454 ] shutil.copytree() quits too soon after an error.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/shutil.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/shutil.py b/Lib/shutil.py index 5bc4377..30116d2 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]) if errors: raise Error, errors |