[game-data-packager] 05/10: Add support for tarballs that do not skip a prefix of the file
Simon McVittie
smcv at debian.org
Sun Jan 4 18:34:48 UTC 2015
This is an automated email from the git hooks/post-receive script.
smcv pushed a commit to branch master
in repository game-data-packager.
commit 9ea3e66986880b4d03c917b7ca615b05065781eb
Author: Simon McVittie <smcv at debian.org>
Date: Sat Jan 3 20:12:05 2015 +0000
Add support for tarballs that do not skip a prefix of the file
---
lib/game_data_packager/__init__.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/game_data_packager/__init__.py b/lib/game_data_packager/__init__.py
index 52414f2..4159522 100644
--- a/lib/game_data_packager/__init__.py
+++ b/lib/game_data_packager/__init__.py
@@ -850,8 +850,9 @@ class GameData(object):
self.use_file(wanted, tmp, None)
elif fmt in ('tar.gz', 'tar.bz2', 'tar.xz'):
rf = open(found_name, 'rb')
- skipped = rf.read(provider.unpack['skip'])
- assert len(skipped) == provider.unpack['skip']
+ if 'skip' in provider.unpack:
+ skipped = rf.read(provider.unpack['skip'])
+ assert len(skipped) == provider.unpack['skip']
with tarfile.open(
found_name,
mode='r|' + fmt[4:],
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/game-data-packager.git
More information about the Pkg-games-commits
mailing list