Commit 550fd5d7 authored by Raymond Hettinger's avatar Raymond Hettinger

Fixed bug 574978 shutil example out of sync with source code

parent 8a9e8b6d
......@@ -112,10 +112,9 @@ def copytree(src, dst, symlinks=0):
linkto = os.readlink(srcname)
os.symlink(linkto, dstname)
elif os.path.isdir(srcname):
copytree(srcname, dstname)
copytree(srcname, dstname, symlinks)
else:
copy2(srcname, dstname)
# XXX What about devices, sockets etc.?
except (IOError, os.error), why:
print "Can't copy %s to %s: %s" % (`srcname`, `dstname`, str(why))
\end{verbatim}
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