[FFmpeg-devel] [PATCH] Remove two 'comparison always false' warnings in libavformat
Mon May 5 00:25:15 CEST 2008
On Sun, May 04, 2008 at 11:40:11PM +0200, Diego 'Flameeyes' Petten? wrote:
> Michael Niedermayer <michaelni at gmx.at> writes:
> > Iam fine with leaving it as int, unless you explain why it should be
> > changed to another type.
> It's returning a size_t value, int might not be big enough to contain
> the size, so there is the chance of an overflow if the value returned is
> bigger than int_max. ssize_t should be big enough to keep the size _and_
> be signed.
I have difficulty imaging a addrlen that does not fit in a 32bit int.
Ill gladly approve a patch using int, if you want to use something else you
will have to quote posix & iso C to proof that our AVERROR codes fit in a
ssize_t also this would be the first ssize_t in ffmpeg, i really have a
bad feeling about this.
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Democracy is the form of government in which you can choose your dictator
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: Digital signature
More information about the ffmpeg-devel