py3k port helpers

This commit is contained in:
Ruud committed 2014-01-20 23:58:54 +01:00
1 parent 08e2a3a883
commit 29a34fef8c
28 files changed
+58 -44

No files matched your search

+3 -2
View File
@@ -15,6 +15,7 @@ import time
import traceback
import version
import zipfile
from six.moves import filter
log = CPLog(__name__)
@@ -350,8 +351,8 @@ class SourceUpdater(BaseUpdater):
try:
if os.path.isdir(path):
shutil.rmtree(path)
except OSError, inst:
os.chmod(inst.filename, 0777)
except OSError as inst:
os.chmod(inst.filename, 0o777)
self.removeDir(path)
def getVersion(self):