From b9d6c895791789ccbc6197adb6fe1806a5e97cc0 Mon Sep 17 00:00:00 2001 From: "P. Christeas" Date: Fri, 10 Jun 2011 12:43:24 +0300 Subject: [PATCH] ir.module: fix bad name of 'zipfile' variable This name is also a library, imported. Avoid using it as a name. (cherry picked from commit fb5bcbbd10447d8d046a84d251217c2b3e8a7ddd) bzr revid: xrg@linux.gr-20110610094324-7rf2uio6g8g3c317 --- openerp/addons/base/module/module.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openerp/addons/base/module/module.py b/openerp/addons/base/module/module.py index 51fdb224918..a549da207d6 100644 --- a/openerp/addons/base/module/module.py +++ b/openerp/addons/base/module/module.py @@ -420,11 +420,11 @@ class module(osv.osv): res.append(mod.url) if not download: continue - zipfile = urllib.urlopen(mod.url).read() + zip_fd = urllib.urlopen(mod.url).read() fname = addons.get_module_path(str(mod.name)+'.zip', downloaded=True) try: fp = file(fname, 'wb') - fp.write(zipfile) + fp.write(zip_fd) fp.close() except Exception: self.__logger.exception('Error when trying to create module '