[asterisk-dev] AST_DATA_IPADDR is broken

Eliel Sardañons eliels at gmail.com
Thu Nov 25 08:57:06 CST 2010


What about having one for each kind of ip address?

AST_DATA_IPADDR
AST_DATA_IPADDR6

On 11/25/2010 10:41 AM, Simon Perreault wrote:
> (Adding Mark Michelson in CC: to get his attention...)
>
> On 2010-11-25 02:21, RAJNIKANT VANZA wrote:
>    
>> /usr/src/asterisk-1.8/asterisk-1.8.0/include/asterisk/data.h:233: error:
>> field ‘AST_DATA_IPADDR’ has incomplete type
>>      
> This is a bug that was introduced by the port to IPv6. Sorry about that.
> I would encourage you to create a new entry in the bug tracker
> (http://issues.asterisk.org).
>
> Basically, we've broken AST_DATA_IPADDR. The breakage is caused by a
> missing #include, so it's easy to fix. But there's a deeper issue:
> AST_DATA_IPADDR can only represent IPv4 addresses. Should it be replaced
> by something that uses ast_sockaddr underneath? From what I can tell,
> AST_DATA_IPADDR is not used within Asterisk itself. This is why this bug
> was not noticed before.
>
> So I see three possibilities:
>
> a. Add the missing #include to make AST_DATA_IPADDR work and move on.
> b. Remove AST_DATA_IPADDR completely.
> c. Replace AST_DATA_IPADDR with AST_DATA_SOCKADDR.
>
> Anyone have an opinion?
>
> Simon
>    




More information about the asterisk-dev mailing list