Skip to content

Commit ac9552c

Browse files
committed
Relax *.ani file length requirement in RIFF header
Many *.ani files online have incorrect length in the RIFF header, see #5, #6
1 parent 21682f6 commit ac9552c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

win2xcur/parser/ani.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def can_parse(cls, blob: bytes) -> bool:
3232
signature, size, subtype = cls.RIFF_HEADER.unpack(blob[:cls.RIFF_HEADER.size])
3333
except struct.error:
3434
return False
35-
return signature == cls.SIGNATURE and size == len(blob) - 8 and subtype == cls.ANI_TYPE
35+
return signature == cls.SIGNATURE and subtype == cls.ANI_TYPE
3636

3737
def __init__(self, blob: bytes) -> None:
3838
super().__init__(blob)

0 commit comments

Comments
 (0)