Permalink
Browse files

Don't use tarfile module on Python < 2.5. It is not reliable

git-svn-id: svn://cherokee-project.com/cherokee/trunk@6184 5dc97367-97f1-0310-9951-d761b3857238
  • Loading branch information...
taher
taher committed Jan 26, 2011
1 parent 0f592c1 commit 2017aa52b019c13cf82aa52a2996aa920fcf8b9d
Showing with 4 additions and 0 deletions.
  1. +4 −0 admin/market/Install.py
View
@@ -28,6 +28,7 @@
import os
import imp
import stat
+import sys
import time
import tarfile
import traceback
@@ -390,6 +391,9 @@ def _Setup_unpack():
# Uncompress
try:
+ if sys.version_info < (2,5): # tarfile module prior to 2.5 is useless to us: http://bugs.python.org/issue1509889
+ raise tarfile.CompressionError
+
Install_Log.log ("Unpacking %s with Python" %(package_path))
tar = tarfile.open (package_path, 'r:gz')
for tarinfo in tar:

0 comments on commit 2017aa5

Please sign in to comment.