lwip-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-commits] [SCM] lwIP - A Lightweight TCPIP stack branch, master


From: Sylvain Rochet
Subject: Re: [lwip-commits] [SCM] lwIP - A Lightweight TCPIP stack branch, master, updated. beabd3c6b789c4dc1c6805b5e8cfe040089fa412
Date: Wed, 22 Apr 2015 19:54:25 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

Hello Simon,

On Wed, Apr 22, 2015 at 10:43:09AM +0000, Simon Goldschmidt wrote:
> 
> Added some macros with extension "_val" that work on actual instances 
> and leave away the "if != NULL" check to get rid of gcc "-Waddress" 
> warnings in the core code at least (I might not have caught all of 
> them, yet)

Humm... there is something wrong with that and I can't find out what 
should be changed.

#define ip6_addr_debug_print_parts(debug, ipaddr) \
  LWIP_DEBUGF(debug, ("%" X16_F ":%" X16_F ":%" X16_F ":%" X16_F ":%" X16_F 
":%" X16_F ":%" X16_F ":%" X16_F, \
                      a, b, c, d, e, f, g, h))
#define ip6_addr_debug_print(debug, ipaddr) \
  ip6_addr_debug_print_parts(debug, \
                      ipaddr != NULL ? IP6_ADDR_BLOCK1(ipaddr) : 0,    \
                      ipaddr != NULL ? IP6_ADDR_BLOCK2(ipaddr) : 0,    \
                      ipaddr != NULL ? IP6_ADDR_BLOCK3(ipaddr) : 0,    \
                      ipaddr != NULL ? IP6_ADDR_BLOCK4(ipaddr) : 0,    \
                      ipaddr != NULL ? IP6_ADDR_BLOCK5(ipaddr) : 0,    \
                      ipaddr != NULL ? IP6_ADDR_BLOCK6(ipaddr) : 0,    \
                      ipaddr != NULL ? IP6_ADDR_BLOCK7(ipaddr) : 0,    \
                      ipaddr != NULL ? IP6_ADDR_BLOCK8(ipaddr) : 0)

ip6_addr_debug_print takes 2 arguments, but 
ip6_addr_debug_print_parts takes 9 arguments, therefore:

lwip/src/core/dns.c: In function ‘dns_lookup’:
lwip/src/core/dns.c:591:60: error: macro "ip6_addr_debug_print_parts" passed 9 
arguments, but takes just 2
       ip_addr_debug_print(DNS_DEBUG, &(dns_table[i].ipaddr));
                                                            ^

Sylvain

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]