[FFmpeg-devel] [PATCH] fix the SAMPLE_FMT_NONE case in ffmdec.c

Ronald S. Bultje rsbultje
Wed Mar 17 16:14:53 CET 2010


Hi,

On Wed, Mar 17, 2010 at 10:42 AM, Michael Niedermayer <michaelni at gmx.at> wrote:
> On Wed, Mar 17, 2010 at 10:20:41AM -0400, Ronald S. Bultje wrote:
>> 2010/3/17 M?ns Rullg?rd <mans at mansr.com>:
>> > "Ronald S. Bultje" <rsbultje at gmail.com> writes:
>> >> 2010/3/16 M?ns Rullg?rd <mans at mansr.com>:
>> >>> My mistake. ?I forgot the exact-width types are special. ?My original
>> >>> statement is still correct though: conversion to a signed type of a
>> >>> value outside the range of that type is implementation-defined, even
>> >>> for fixed-width types.
>> >>
>> >> So what is the consensus? int16_t cast or sign_extend()? I want to
>> >> apply this patch, this is a bug that should be fixed.
>> >
>> > Cast is fine with me if this is the only place it's needed. ?Otherwise
>> > a companion function to get_le16() reading a signed value would be the
>> > preferable solution.
>>
>> Michael? Your preference?
>
> cast as its standard C, anything else complicates understanding of the code

Applied.

Ronald



More information about the ffmpeg-devel mailing list