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 81c43e8f9183b786e31230c9a39b77315fdc87ef
Author: Simon McVittie <[email protected]>
Date:   Wed Dec 30 12:56:48 2015 +0000

    Fix streaming entries from tar files
---
 game_data_packager/unpack/__init__.py | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/game_data_packager/unpack/__init__.py 
b/game_data_packager/unpack/__init__.py
index 59373a6..25c000f 100644
--- a/game_data_packager/unpack/__init__.py
+++ b/game_data_packager/unpack/__init__.py
@@ -104,8 +104,18 @@ class StreamUnpackable(metaclass=ABCMeta):
         """Extract the given member from the archive into the given
         directory.
         """
-        with self.open(member) as reader:
-            filename = reader.entry.name
+
+        if isinstance(member, (str, bytes)):
+            filename = member
+        else:
+            filename = member.name
+
+        reader = self.open(member)
+
+        if not reader:
+            raise ValueError('cannot open %s' % member)
+
+        with reader:
             filename = filename.lstrip('/')
 
             while filename.startswith('../'):

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/pkg-games/game-data-packager.git

_______________________________________________
Pkg-games-commits mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-games-commits

Reply via email to