[MPlayer-dev-eng] [PATCH] 'socklen_t' definition

KO Myung-Hun komh at chollian.net
Thu Jul 31 16:01:21 CEST 2008



Diego Biurrun wrote:
> On Thu, Jul 31, 2008 at 12:30:17AM +0900, KO Myung-Hun wrote:
>   
>> Diego Biurrun wrote:
>>     
>>> On Wed, Jul 30, 2008 at 12:06:36AM +0900, KO Myung-Hun wrote:
>>>   
>>>       
>>>> Some system such as OS/2, 'socklen_t is not defined. So we need to check
>>>> its definition and if needed, should defined it.
>>>>
>>>> But, this check and definition can conflict with other systems. So set
>>>> its default value to 'HAVE', and check only on OS/2, finally if needed
>>>> define 'socklen_t'.
>>>>
>>>> Can this approach make a trouble with systems other than OS/2 ?
>>>>         
>>> I just committed a different check.  Testing on Windows is welcome.
>>>   
>>>       
>> Additional patch.
>>
>> 1. _socklen_t should be initialized to 'no'
>>     
>
> I don't see what this helps.
>
>   

At least, it display result is 'no' instead of emptiness when 
'socklen_t' is not found.

>> 2. if 'socklen_t' is defined, 'HAVE_SOCKLEN_T' should be defined, too.  
>> Otherwise, this can conflict with 'socklen_t ' definition of  
>> libavformat. Although CONFIG_NETWORK solve this, fortunately. this can  
>> be a potential problem whenever.
>>     
>
> Is this a real problem or does it just generate a warning?
> Anyway, changed.
>   

It is a error not a warning, so it break compilation process.

Thanks.

>   
>> 3.  Check Win32 env using '_winsock2'. If _winsock2 is yes, we can  
>> assume that socklen_t is defined.
>>     
>
> Such assumptions make the code non-portable.  I have added a check
> instead.
>   

Great!

-- 
KO Myung-Hun

Using Mozilla SeaMonkey 1.1.9
Under OS/2 Warp 4 for Korean with FixPak #15
On AMD ThunderBird 1 GHz with 512 MB RAM

Korean OS/2 User Community : http://www.ecomstation.co.kr





More information about the MPlayer-dev-eng mailing list