Fix more exception slicing.

This commit is contained in:
Georg Brandl 2008-01-06 21:13:42 +00:00
parent 7357c23ee7
commit d11b68ab08
9 changed files with 15 additions and 15 deletions

View file

@ -139,7 +139,7 @@ def copy_file(src, dst, preserve_mode=1, preserve_times=1, update=0,
macostools.copy(src, dst, 0, preserve_times)
except os.error as exc:
raise DistutilsFileError(
"could not copy '%s' to '%s': %s" % (src, dst, exc[-1]))
"could not copy '%s' to '%s': %s" % (src, dst, exc.args[-1]))
# If linking (hard or symbolic), use the appropriate system call
# (Unix only, of course, but that's the caller's responsibility)