aboutsummaryrefslogtreecommitdiff
path: root/tests/CMakeLists.txt
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2021-01-03 10:58:38 -0800
committerGarrett D'Amore <garrett@damore.org>2021-01-03 15:03:15 -0800
commit6a9bd051c439ef66cf00795b3829ca3ceece0497 (patch)
treef0c30c7c3d9c6ceb38ea3bd2175f07217df1f24c /tests/CMakeLists.txt
parentf82096d39f21f30ac11fcf1c65a5b25e85691eae (diff)
downloadnng-6a9bd051c439ef66cf00795b3829ca3ceece0497.tar.gz
nng-6a9bd051c439ef66cf00795b3829ca3ceece0497.tar.bz2
nng-6a9bd051c439ef66cf00795b3829ca3ceece0497.zip
fixes #1401 valgrind reports leaks in all tests
This arranges for nng_fini to be called via atexit in the test version of the library. It also cleans up some of the actual tests to reduce extraneous (and in some cases incorrect) calls to nng_fini.
Diffstat (limited to 'tests/CMakeLists.txt')
-rw-r--r--tests/CMakeLists.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 9ff9adfa..5fcd4323 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -64,7 +64,7 @@ if (NNG_TESTS)
# are present. It's not worth trying to figure out which of these
# should work and which shouldn't.
macro(add_nng_compat_test NAME TIMEOUT)
- add_executable(${NAME} ${NAME}.c nuts_compat.c)
+ add_executable(${NAME} ${NAME}.c compat_testutil.c)
target_link_libraries(${NAME} nng_testing)
target_include_directories(${NAME} PRIVATE
${PROJECT_SOURCE_DIR}/src/compat