[FFmpeg-devel] [PATCH] alac : check readsamplesize
Mon Jul 14 10:02:33 CEST 2008
Jai Menon wrote:
>> check readsamplesize in alac, with the current code, it could be
>> negative or bigger than 17 (and get_bits will fail).
> And what about 24-bit alac streams? not to mention multi-channel alac if possible
> that is...
ATM ffmpeg decoder doesn't support 24-bit stream, nor multi-channel :
- get_bits will return garbage if readsamplesize > 17
- in the 24-bit stream I saw on mplayer sample, wasted_bytes is used, so
readsamplesize could be less than 17, but our decoder doesn't handle it
- for not 16-bit stream, we got 'FIXME: unimplemented sample size'.
- MAX_CHANNELS is 2
So until we implement correct support for multi-channel and other bits
per sample, I think this check is safe.
More information about the ffmpeg-devel