From ef5a32cfd3c0555ffe5ddf413eeaae61622ebb4b Mon Sep 17 00:00:00 2001 From: jvoisin Date: Sun, 8 Jun 2014 01:37:07 +0200 Subject: Improves zip handling - ZIP_EPOCH is now set correctly - list_unsupported should now work This also fix the testsuite. --- MAT/archive.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/MAT/archive.py b/MAT/archive.py index 4ffe21a..d483dcc 100644 --- a/MAT/archive.py +++ b/MAT/archive.py @@ -16,7 +16,7 @@ import parser # Zip files do not support dates older than 01/01/1980 ZIP_EPOCH = (1980, 1, 1, 0, 0, 0) ZIP_EPOCH_SECONDS = (datetime.datetime(1980, 1, 1, 0, 0, 0) - - datetime.datetime(1970, 1, 1, 0, 0, 0)).total_seconds() + - datetime.datetime(1970, 1, 1, 1, 0, 0)).total_seconds() class GenericArchiveStripper(parser.GenericParser): @@ -95,7 +95,6 @@ class ZipStripper(GenericArchiveStripper): logging.debug('%s from %s has metadata' % (item.filename, self.filename)) if not list_unsupported: return False - ret_list.append(item.filename) else: logging.info('%s\'s fileformat is not supported or harmless.' % item.filename) -- cgit v1.3