lwip-devel
[Top][All Lists]
Advanced

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

[lwip-devel] lwip_unittests crash


From: Gisle Vanem
Subject: [lwip-devel] lwip_unittests crash
Date: Tue, 25 Aug 2015 14:12:54 +0200
User-agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:36.0) Gecko/20100101 Firefox/36.0 SeaMonkey/2.33.1

Hi list.

I've built lwIP on Windows 8.1 (using MSVC + MingW). The lwip.dll
and my test-app seems to work fine (LWIP_DHCP=1).

But the lwip_unittest program crashes inside in ip4_route()
(src/core/ipv4/ip4.c, line 145):

  /* iterate through netifs */
  for (netif = netif_list; netif != NULL; netif = netif->next) {

The value of 'netif' is 0x00000100 !! Hence the
'netif->next' also contains rubbish.

Someone who can shed some light on this?

After enabling full debug in lwip_unittest, I get:

  lwip_debug_flags: 0xff
  netif: netmask of interface  <0><0>  set to 255.0.0.0
  netif: GW address of interface  <0><0>  set to 127.0.0.1
  netif_set_ipaddr: netif address being changed
  netif: IP address of interface  <0><0>  set to 127.0.0.1
  netif: added interface lo IP addr 127.0.0.1 netmask 255.0.0.0 gw 127.0.0.1
  udp_bind(ipaddr = 0.0.0.0, port = 161)
  udp_bind: bound to 0.0.0.0, port 161)
  igmp_init: initializing
  Running suite(s): UDP
   TCP
  inet_chksum_pseudo(): checksumming pbuf 00D81AF8 (has next 00000000)
  inet_chksum_pseudo(): pbuf chain lwip_chksum()=445f
  inet_chksum_pseudo(): checksumming pbuf 00D81AF8 (has next 00000000)
  inet_chksum_pseudo(): pbuf chain lwip_chksum()=ffff
  inet_chksum_pseudo(): checksumming pbuf 00D62C60 (has next 00000000)
  inet_chksum_pseudo(): pbuf chain lwip_chksum()=4a5b
  ip_output_if: ↑☻0     << ! where does this rubbish come from?
  IP header:
  +-------------------------------+
  | 4 | 5 |  0x00 |        40     | (v, hl, tos, len)
  +-------------------------------+
  |        0      |000|       0   | (id, flags, offset)
  +-------------------------------+
  |  255  |    6  |    0x387c     | (ttl, proto, chksum)
  +-------------------------------+
  |  192  |  168  |    1  |    1  | (src)
  +-------------------------------+
  |  192  |  168  |    1  |    2  | (dest)
  +-------------------------------+
  netif_loop_output()inet_chksum_pseudo(): checksumming pbuf 00D62C60 (has next 
00000000)
  inet_chksum_pseudo(): pbuf chain lwip_chksum()=2425
  <crashes here>

Could the test_netif.name[] = <0><0> and the rubbish after
'ip_output_if' have anything to do with this crash?

--
--gv



reply via email to

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