Closed milesegan closed 1 week ago
It seems like maybe the issue is here?
When I read the tag the content
is [0, 0, 0, 1]
which gets parsed as false. Maybe an endian issue?
Yep, that's exactly where the issue is :)
These flag atoms seem to be pretty inconsistently implemented. Quite a few projects write a 1 byte flag (which is what I thought was correct). It seems like other tools (including iTunes) write an i32
, though. Guess I'll have to account for both encodings during parsing.
It sounds tricky! Please let me know if I can help out.
Reproducer
Repo for reproduction is here:
https://github.com/milesegan/lofty-aac-compilation-bug
Summary
There seems to be an error reading the
cpil
compilation flag field from m4a tags. In the sample file the value is 1 but the tag reads as 0.Expected behavior
No response
Assets
No response