RafaGago / mini-async-log-c

Mini async log C port. Now with C++ wrappers.
BSD 3-Clause "New" or "Revised" License
71 stars 7 forks source link

Tests failing on Ubuntu 22.04 #5

Closed jay-sridharan closed 1 year ago

jay-sridharan commented 1 year ago

I am trying to build and run tests, but I am getting this list of failures. Seems to be some segfaults.

Summary of Failures:

 8/20 base_library / taskqueue-stress                 FAIL            0.08s   exit status 1
 9/20 mini-async-log-c / malc-stress-test-heap        FAIL            0.08s   exit status 1
10/20 mini-async-log-c / malc-stress-test-tls         FAIL            0.08s   exit status 1
11/20 mini-async-log-c / malcpp-smoke                 FAIL            0.09s   exit status 24
12/20 mini-async-log-c / malcpp-stress-test-heap      FAIL            0.08s   exit status 1
13/20 mini-async-log-c / malc-stress-test-queue       FAIL            0.09s   exit status 1
14/20 mini-async-log-c / malc-stress-test-queue-cpu   FAIL            0.09s   exit status 1
15/20 mini-async-log-c / malcpp-stress-test-tls       FAIL            0.10s   exit status 1
16/20 mini-async-log-c / malcpp-stress-test-queue     FAIL            0.09s   exit status 1
18/20 mini-async-log-c / malcpp-stress-test-queue-cpu FAIL            0.10s   exit status 1
19/20 base_library / bl-base                          FAIL            0.16s   exit status 1
20/20 mini-async-log-c / malc-smoke                   TIMEOUT        30.03s   killed by signal 15 SIGTERM

I have attached the test log as well tests.tar.gz

jay-sridharan commented 1 year ago

I believe this line is the cause for the segfault in malc-smoke

https://github.com/RafaGago/base_library/blob/3d08c1ccbecc4ab26495999fc6692978b490e40f/include/bl/base/impl/thread_c11.h#L44

thrd_create takes a thrd_t, not a thrd_t*. The t argument needs to be dereferenced.

RafaGago commented 1 year ago

I forgot to write yesterday, but thanks for reporting, this is fixed on https://github.com/RafaGago/mini-async-log-c/commit/67fabe26d1f73ff75b0ee9e22dede4242a1c57c5

It seems that the default GCC version is now updated C11 and that code was wrong. Good catch.