summaryrefslogtreecommitdiff
path: root/Lib/aifc.py
diff options
context:
space:
mode:
authorR. David Murray <rdmurray@bitdance.com>2009-04-29 15:34:32 +0000
committerR. David Murray <rdmurray@bitdance.com>2009-04-29 15:34:32 +0000
commitb507d2e07d19692df25a07c82f6d96ff1e4b4313 (patch)
treece4801b966c66fb22166eea7230b6b36a89d7f1d /Lib/aifc.py
parentaa17a7fc98773e0f2b2a23e59a0a2b3d9f1bca84 (diff)
downloadcpython-git-b507d2e07d19692df25a07c82f6d96ff1e4b4313.tar.gz
Merged revisions 72100-72101 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r72100 | r.david.murray | 2009-04-29 09:17:37 -0400 (Wed, 29 Apr 2009) | 7 lines Fix issue 2245. aifc now skips any chunk type it doesn't actually process instead of throwing errors for anything not in an explicit skip list. This is per this spec: http://www.cnpbagwell.com/aiff-c.txt. Spec reference and test sound file provided by Santiago Peresón, fix based on patch by Hiroaki Kawai. ........ r72101 | r.david.murray | 2009-04-29 09:51:44 -0400 (Wed, 29 Apr 2009) | 2 lines Now that we've got a test_aifc, add a few tests. ........
Diffstat (limited to 'Lib/aifc.py')
-rw-r--r--Lib/aifc.py8
1 files changed, 0 insertions, 8 deletions
diff --git a/Lib/aifc.py b/Lib/aifc.py
index 26b0ff5b7a..36312b3c2c 100644
--- a/Lib/aifc.py
+++ b/Lib/aifc.py
@@ -144,9 +144,6 @@ class Error(Exception):
_AIFC_version = 0xA2805140 # Version 1 of AIFF-C
-_skiplist = b'COMT', b'INST', b'MIDI', b'AESD', \
- b'APPL', b'NAME', b'AUTH', b'(c) ', b'ANNO'
-
def _read_long(file):
try:
return struct.unpack('>l', file.read(4))[0]
@@ -313,11 +310,6 @@ class Aifc_read:
self._version = _read_ulong(chunk)
elif chunkname == b'MARK':
self._readmark(chunk)
- elif chunkname in _skiplist:
- pass
- else:
- raise Error('unrecognized chunk type ' +
- chunkname.decode('latin1'))
chunk.skip()
if not self._comm_chunk_read or not self._ssnd_chunk:
raise Error('COMM chunk and/or SSND chunk missing')