[MPlayer-dev-eng] Re: [PATCH] updated diff for libdvdread-0.9.5

The Wanderer inverseparadox at comcast.net
Wed Apr 19 10:32:06 CEST 2006


Rich Felker wrote:

> On Tue, Apr 18, 2006 at 04:42:02PM +0200, Diego Biurrun wrote:
> 
>> On Wed, Mar 22, 2006 at 10:45:02PM +0100, Emanuele Giaquinta wrote:
>> 
>>> This patch fixes the rtp demuxer with the new libdvdread;
>>> ifo_types.h needs the macros UINT8_MAX UINT16_MAX and INT32_MAX,
>>> in stdint.h, which are not defined when the language is c++
>>> unless
>>> __STDC_LIMIT_MACROS
>>> is defined.
>> 
>> Patch applied, thanks.
> 
> Incidentally, using UINT8_MAX UINT16_MAX and INT32_MAX is absolutely
> idiotic. These are not system-specific limits but the numbers 255,
> 65535, and 2147483647.

That doesn't necessarily make it idiotic to use symbolic names for them;
it makes the code (potentially/arguably) more readable, by referring to
the reason why this specific number is being used instead of just having
an apparently arbitrary number. I've done vaguely similar things in some
of my own code, a few times in the past, albeit with names I defined
myself rather than more broadly general ones.

-- 
       The Wanderer

Warning: Simply because I argue an issue does not mean I agree with any
side of it.

Secrecy is the beginning of tyranny.




More information about the MPlayer-dev-eng mailing list