[MERGE] base: rename zipfile variable into zip_content (because zipname is an imported module).

lp bug: https://launchpad.net/bugs/795452 fixed

bzr revid: vmt@openerp.com-20110915102117-sep3t0itkjjmertz
This commit is contained in:
Vo Minh Thu
2011-09-15 12:21:17 +02:00
+2 -2
View File
@@ -437,11 +437,11 @@ class module(osv.osv):
res.append(mod.url)
if not download:
continue
zipfile = urllib.urlopen(mod.url).read()
zip_content = 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_content)
fp.close()
except Exception:
self.__logger.exception('Error when trying to create module '