From a8c69e78856ea0914362d799b2cd6dde016c7fd9 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Tue, 18 Aug 2009 19:12:26 +0200 Subject: [PATCH] [FIX] correct translation tgz archive creation lp bug: https://launchpad.net/bugs/415014 fixed bzr revid: christophe@tinyerp.com-20090818171226-uu6v31pr0zrmne0k --- bin/tools/translate.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/tools/translate.py b/bin/tools/translate.py index 736afdf8446..1c0557908cf 100644 --- a/bin/tools/translate.py +++ b/bin/tools/translate.py @@ -313,8 +313,9 @@ def trans_export(lang, modules, buffer, format, dbname=None): tmpmoddir = join(tmpdir, mod, 'i18n') os.makedirs(tmpmoddir) pofilename = (newlang and mod or lang) + ".po" + (newlang and 't' or '') - buf = open(join(tmpmoddir, pofilename), 'w') + buf = file(join(tmpmoddir, pofilename), 'w') _process('po', [mod], modrows, buf, lang, newlang) + buf.close() tar = tarfile.open(fileobj=buffer, mode='w|gz') tar.add(tmpdir, '')