changeset 14742:271424fdbeec stable

archive: wrap the ui descriptor so it doesn't get closed archival.tarit closes the fileobj if one is passed to it, which is undesired when reading from '-'.
author Idan Kamara <idankk86@gmail.com>
date Fri, 24 Jun 2011 17:04:37 +0300
parents 39235b398248
children 84a680daa4b2
files mercurial/commands.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/commands.py	Fri Jun 24 19:27:53 2011 +0300
+++ b/mercurial/commands.py	Fri Jun 24 17:04:37 2011 +0300
@@ -337,7 +337,7 @@
     if dest == '-':
         if kind == 'files':
             raise util.Abort(_('cannot archive plain files to stdout'))
-        dest = ui.fout
+        dest = cmdutil.makefileobj(repo, dest)
         if not prefix:
             prefix = os.path.basename(repo.root) + '-%h'