[FFmpeg-devel] [PATCH] alac : check readsamplesize

matthieu castet castet.matthieu
Mon Jul 14 10:02:33 CEST 2008


Hi,

Jai Menon wrote:
> Hi,

> 
>> 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 
correctly
- 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.


Matthieu




More information about the ffmpeg-devel mailing list