summaryrefslogtreecommitdiff
path: root/rdiff-backup/rdiff_backup/statistics.py
diff options
context:
space:
mode:
authorjoshn <joshn@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109>2009-06-04 23:50:58 +0000
committerjoshn <joshn@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109>2009-06-04 23:50:58 +0000
commit55a4a7d925ab079617e74113d448f4540661e317 (patch)
treecf7eb6eae3a08893702c4ca5bccd3198df25171e /rdiff-backup/rdiff_backup/statistics.py
parent2717ce34a4c17ad87b021a0a51be89164ef7a2c3 (diff)
downloadrdiff-backup-55a4a7d925ab079617e74113d448f4540661e317.tar.gz
Gah. Fix unicode support for linux systems where the destination Python installation doesn't support unicode filenames.
git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup/trunk@1057 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109
Diffstat (limited to 'rdiff-backup/rdiff_backup/statistics.py')
-rw-r--r--rdiff-backup/rdiff_backup/statistics.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/rdiff-backup/rdiff_backup/statistics.py b/rdiff-backup/rdiff_backup/statistics.py
index 1df602a..50ba3be 100644
--- a/rdiff-backup/rdiff_backup/statistics.py
+++ b/rdiff-backup/rdiff_backup/statistics.py
@@ -219,13 +219,13 @@ class StatsObj:
def write_stats_to_rp(self, rp):
"""Write statistics string to given rpath"""
- fp = rpath.UnicodeFile(rp.open("wb"))
+ fp = rpath.MaybeUnicode(rp.open("wb"))
fp.write(self.get_stats_string())
assert not fp.close()
def read_stats_from_rp(self, rp):
"""Set statistics from rpath, return self for convenience"""
- fp = rpath.UnicodeFile(rp.open("r"))
+ fp = rpath.MaybeUnicode(rp.open("r"))
self.set_stats_from_string(fp.read())
fp.close()
return self
@@ -364,7 +364,7 @@ class FileStats:
suffix = Globals.compression and 'data.gz' or 'data'
cls._rp = increment.get_inc(rpbase, suffix, Time.curtime)
assert not cls._rp.lstat()
- cls._fileobj = rpath.UnicodeFile(cls._rp.open("wb",
+ cls._fileobj = rpath.MaybeUnicode(cls._rp.open("wb",
compress = Globals.compression))
cls._line_sep = Globals.null_separator and '\0' or '\n'