changeset 843:df2c85478063

Merge with stable
author Augie Fackler <durin42@gmail.com>
date Tue, 01 Nov 2011 15:50:13 -0500
parents 6c4d15d8cfbd (current diff) 794f3e41ec1e (diff)
children 95d040755254
files hgsubversion/editor.py
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/hgsubversion/editor.py
+++ b/hgsubversion/editor.py
@@ -342,10 +342,13 @@ class HgEditor(svnwrap.Editor):
             try:
                 if not self.meta.is_path_valid(self.current.file):
                     return
+                # Already get and store the value here, because calling
+                # handler(window) seems to close the target in Subversion 1.7.
+                val = target.getvalue()
                 handler(window)
                 # window being None means commit this file
                 if not window:
-                    self.current.files[self.current.file] = target.getvalue()
+                    self.current.files[self.current.file] = val
             except svnwrap.SubversionException, e: # pragma: no cover
                 if e.args[1] == svnwrap.ERR_INCOMPLETE_DATA:
                     self.current.missing.add(self.current.file)