diff mercurial/cmdutil.py @ 6258:c24f4b3f156b

Fix issue995 (copy --after and symlinks pointing to a directory) I haven't looked at other places that call os.path.isdir to make sure they're OK.
author Alexis S. L. Carvalho <alexis@cecm.usp.br>
date Fri, 14 Mar 2008 10:32:19 -0300
parents f89fd07fc51d
children dfdef3d560a8
line wrap: on
line diff
--- a/mercurial/cmdutil.py	Fri Mar 14 09:56:58 2008 -0300
+++ b/mercurial/cmdutil.py	Fri Mar 14 10:32:19 2008 -0300
@@ -470,7 +470,7 @@
     if len(pats) == 1:
         raise util.Abort(_('no destination specified'))
     dest = pats.pop()
-    destdirexists = os.path.isdir(dest)
+    destdirexists = os.path.isdir(dest) and not os.path.islink(dest)
     if not destdirexists:
         if len(pats) > 1 or util.patkind(pats[0], None)[0]:
             raise util.Abort(_('with multiple sources, destination must be an '