[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] r21237: {projects} Enable exe file renaming code (projects/gettor/lib/gettor)
Author: kaner
Date: 2009-12-16 17:15:26 -0500 (Wed, 16 Dec 2009)
New Revision: 21237
Modified:
projects/gettor/lib/gettor/packages.py
Log:
Enable exe file renaming code
Modified: projects/gettor/lib/gettor/packages.py
===================================================================
--- projects/gettor/lib/gettor/packages.py 2009-12-16 21:57:11 UTC (rev 21236)
+++ projects/gettor/lib/gettor/packages.py 2009-12-16 22:15:26 UTC (rev 21237)
@@ -214,23 +214,23 @@
if re.compile(".*split.part.*").match(splitfile):
ascfile = splitdir + "/signatures/" + splitfile + ".asc"
# Rename .exe if needed
- #if gettor.utils.hasExe(ascfile):
- # try:
- # ascfile = gettor.utils.renameExe(ascfile)
- # except:
- # log.error("Could not rename exe file")
+ if gettor.utils.hasExe(ascfile):
+ try:
+ ascfile = gettor.utils.renameExe(ascfile)
+ except:
+ log.error("Could not rename exe file")
file = splitdir + "/" + splitfile
- #if gettor.utils.hasExe(file):
- # try:
- # file = gettor.utils.renameExe(file)
- # except:
- # log.error("Could not rename exe file")
+ if gettor.utils.hasExe(file):
+ try:
+ file = gettor.utils.renameExe(file)
+ except:
+ log.error("Could not rename exe file")
zipFileName = packSplitDir + "/" + splitfile + ".z"
- #if gettor.utils.hasExe(file):
- # try:
- # zipFileName = gettor.utils.renameExe(zipFileName)
- # except:
- # log.error("Could not rename exe file")
+ if gettor.utils.hasExe(file):
+ try:
+ zipFileName = gettor.utils.renameExe(zipFileName)
+ except:
+ log.error("Could not rename exe file")
if os.access(ascfile, os.R_OK) and os.access(file, os.R_OK):
zip = zipfile.ZipFile(zipFileName, "w")
zip.write(file, os.path.basename(file))