lwip-devel
[Top][All Lists]
Advanced

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

[lwip-devel] [bug #51652] Unit test errors appear


From: Andrey Vinogradov
Subject: [lwip-devel] [bug #51652] Unit test errors appear
Date: Thu, 3 Aug 2017 19:58:27 -0400 (EDT)
User-agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36

URL:
  <http://savannah.nongnu.org/bugs/?51652>

                 Summary: Unit test errors appear
                 Project: lwIP - A Lightweight TCP/IP stack
            Submitted by: andreyvinogradov
            Submitted on: Thu 03 Aug 2017 11:58:26 PM UTC
                Category: None
                Severity: 3 - Normal
              Item Group: Faulty Behaviour
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: None
            lwIP version: git head

    _______________________________________________________

Details:

I was playing with yarricks travis-ci and got unit test errors:
first:

compiler gcc-5:
https://travis-ci.org/Kira-sempai/lwip-merged/jobs/260786636

gcc-5 -DLWIP_NOASSERT_ON_ERROR -I/usr/include/check
-I../../../../lwip/src/../test/unit -g -Wall -DLWIP_DEBUG -pedantic -Werror
-Wparentheses -Wsequence-point -Wswitch-default -Wextra -Wundef -Wshadow
-Wpointer-arith -Wcast-qual -Wc++-compat -Wwrite-strings
-Wold-style-definition -Wcast-align -Wmissing-prototypes -Wredundant-decls
-Wnested-externs -Wunreachable-code -Wuninitialized -Wlogical-op -I.
-I../../.. -I../../../../lwip/src/include -I../../../ports/unix/port/include
-o lwip_unittests lwip_unittests.o test_sockets.o sys_arch.o test_mem.o
test_pbuf.o test_dhcp.o test_etharp.o test_ip4.o test_mdns.o test_mqtt.o
tcp_helper.o test_tcp_oos.o test_tcp.o test_udp.o  -Wl,--start-group
liblwipcommon.a liblwipapps.a -pthread -lutil -lrt -lcheck -lm -lsubunit
-Wl,--end-group
/usr/lib/gcc/x86_64-linux-gnu/5/../../../x86_64-linux-gnu/libcheck.a(check_run.o):
In function `srunner_run':
(.text+0x965): undefined reference to `timer_create'
/usr/lib/gcc/x86_64-linux-gnu/5/../../../x86_64-linux-gnu/libcheck.a(check_run.o):
In function `srunner_run':
(.text+0x9b3): undefined reference to `timer_settime'
/usr/lib/gcc/x86_64-linux-gnu/5/../../../x86_64-linux-gnu/libcheck.a(check_run.o):
In function `srunner_run':
(.text+0x9d9): undefined reference to `timer_delete'

Solution:
contrib/unix/check/Makefile, line 42:
LDFLAGS:= -lcheck -lm -lsubunit $(LDFLAGS)

changing link position helps. Same problem was described here:
https://codedump.io/share/twca8C3P7mq9/1/undefined-reference-to-a-function-in-another-library

second:
compiler clang-3.8
runtime errors:
https://travis-ci.org/Kira-sempai/lwip-merged/jobs/260820629

 ETHARP
../../../../lwip/src/core/tcp.c:2063:10: runtime error:
member access within null pointer of type 'const ip_addr_t' (aka
'const struct ip_addr')
SUMMARY: AddressSanitizer: undefined-behavior
../../../../lwip/src/core/tcp.c:2063:10 in 
../../../../lwip/src/core/tcp.c:2063:10: runtime error:
member access within null pointer of type 'const union (anonymous
union at ../../../../lwip/src/include/lwip/ip_addr.h:70:3)'
SUMMARY: AddressSanitizer: undefined-behavior
../../../../lwip/src/core/tcp.c:2063:10 in 
../../../../lwip/src/core/udp.c:1211:36: runtime error:
member access within null pointer of type 'const ip_addr_t' (aka
'const struct ip_addr')
SUMMARY: AddressSanitizer: undefined-behavior
../../../../lwip/src/core/udp.c:1211:36 in 
../../../../lwip/src/core/udp.c:1211:36: runtime error:
member access within null pointer of type 'const union (anonymous
union at ../../../../lwip/src/include/lwip/ip_addr.h:70:3)'
SUMMARY: AddressSanitizer: undefined-behavior
../../../../lwip/src/core/udp.c:1211:36 in 






    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/bugs/?51652>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.nongnu.org/




reply via email to

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