[FFmpeg-devel] [PATCH] Use more appropriate types when decoding vorbisfloats
Alex Converse
alex.converse
Sat Jul 24 04:19:08 CEST 2010
On Fri, Jul 23, 2010 at 10:15 PM, Rafa?l Carr? <rafael.carre at gmail.com> wrote:
> On Fri, 23 Jul 2010 18:10:45 -0400
> Alex Converse <alex.converse at gmail.com> wrote:
>
> Hi,
>
>> Index: libavcodec/vorbis_dec.c
>> ===================================================================
>> --- libavcodec/vorbis_dec.c ? (revision 24471)
>> +++ libavcodec/vorbis_dec.c ? (working copy)
>> @@ -178,11 +178,11 @@
>>
>> ?static float vorbisfloat2float(uint_fast32_t val)
>> ?{
>> - ? ?double mant = val & 0x1fffff;
>> - ? ?long exp ? ?= (val & 0x7fe00000L) >> 21;
>> + ? ?float mant = val & 0x1fffff;
>> + ? ?int exp ? ?= (val & 0x7fe00000L) >> 21;
> ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ^
> Shouldn't the L be dropped too?
Yes, good catch.
More information about the ffmpeg-devel
mailing list