Commit 6e9ae2e3 authored by Christophe Dumez's avatar Christophe Dumez

- fixed missing import / class

- improved error messages


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@7451 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent d1fc8deb
......@@ -271,7 +271,12 @@
from dircache import listdir
from shutil import copy
import os
import os, exceptions
class Error(exceptions.EnvironmentError):
""" Simple Exception
"""
pass
def copytree(src, dst, symlinks=False):
"""Recursively copy a directory tree using copy().
......@@ -303,6 +308,6 @@ def copytree(src, dst, symlinks=False):
else:
copy(srcname, dstname)
except (IOError, os.error), why:
errors.append((srcname, dstname, 'Error: ' + str(why.strerror)))
errors.append((srcname, dstname, str(why)))
if errors:
raise Error, errors
\ No newline at end of file
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