The branch, master has been updated via db887c0 Bump version to 1.1.15 via 21447f6 tests: Fix a memory leak in test_nwrap_initgroups() via baa8dad cmake: Set default compile flags for nss_utils via e686be6 cmake: We need to link nss_nwrap against nss_utils from 3291b07 Bump version to 1.1.14
https://git.samba.org/?p=nss_wrapper.git;a=shortlog;h=master - Log ----------------------------------------------------------------- commit db887c00d35b1504abe72a30fe386111e9a25ed2 Author: Andreas Schneider <a...@samba.org> Date: Wed Jan 25 12:43:23 2023 +0100 Bump version to 1.1.15 Signed-off-by: Andreas Schneider <a...@samba.org> Reviewed-by: Pavel Filipenský <pfilipen...@samba.org> commit 21447f6c38390118984853adee978ab48b24e432 Author: Andreas Schneider <a...@samba.org> Date: Wed Jan 25 13:23:35 2023 +0100 tests: Fix a memory leak in test_nwrap_initgroups() Signed-off-by: Andreas Schneider <a...@samba.org> Reviewed-by: Pavel Filipenský <pfilipen...@samba.org> commit baa8dadd6ab9f654024873c8b170d66285782f3b Author: Andreas Schneider <a...@samba.org> Date: Wed Jan 25 12:38:01 2023 +0100 cmake: Set default compile flags for nss_utils Signed-off-by: Andreas Schneider <a...@samba.org> Reviewed-by: Pavel Filipenský <pfilipen...@samba.org> commit e686be6ff3da062225287980a3d27ab2f385651f Author: Andreas Schneider <a...@samba.org> Date: Wed Jan 25 12:34:57 2023 +0100 cmake: We need to link nss_nwrap against nss_utils tests/nss_nwrap.c:240: undefined reference to `nwrap_gr_copy_r' Signed-off-by: Andreas Schneider <a...@samba.org> Reviewed-by: Pavel Filipenský <pfilipen...@samba.org> ----------------------------------------------------------------------- Summary of changes: CHANGELOG | 4 ++++ CMakeLists.txt | 2 +- src/CMakeLists.txt | 4 ++++ tests/CMakeLists.txt | 1 + tests/test_initgroups.c | 1 + 5 files changed, 11 insertions(+), 1 deletion(-) Changeset truncated at 500 lines: diff --git a/CHANGELOG b/CHANGELOG index aed76b3..2cd0423 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,6 +1,10 @@ ChangeLog ========== +version 1.1.15 (released 2023-01-25) + * Fixed linking issue in tests + * Fixed a memory leak in tests + version 1.1.14 (released 2023-01-25) * Fixed implementation of initgroups() * Fixed implementation of getgrouplist() diff --git a/CMakeLists.txt b/CMakeLists.txt index bd3b663..2f7c91a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -11,7 +11,7 @@ list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/Modules") include(DefineCMakeDefaults) include(DefineCompilerFlags) -project(nss_wrapper VERSION 1.1.14 LANGUAGES C) +project(nss_wrapper VERSION 1.1.15 LANGUAGES C) # global needed variables set(APPLICATION_NAME ${PROJECT_NAME}) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index f56aad5..a920191 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,6 +1,10 @@ project(libnss_wrapper C) add_library(nss_utils STATIC nss_utils.c) +target_compile_options(nss_utils + PRIVATE + ${DEFAULT_C_COMPILE_FLAGS}) + add_library(nss_wrapper SHARED nss_wrapper.c) target_compile_options(nss_wrapper PRIVATE diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 425395b..3b94076 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -11,6 +11,7 @@ target_include_directories(nss_nwrap PRIVATE ${CMAKE_BINARY_DIR} ${CMOCKA_INCLUDE_DIR}) +target_link_libraries(nss_nwrap PRIVATE nss_utils) set(HOMEDIR ${CMAKE_CURRENT_BINARY_DIR}) diff --git a/tests/test_initgroups.c b/tests/test_initgroups.c index 959ae4d..1ec2220 100644 --- a/tests/test_initgroups.c +++ b/tests/test_initgroups.c @@ -35,6 +35,7 @@ static void test_nwrap_initgroups(void **state) for (i = 0; i < 6; i++) { assert_int_equal(groups1[i], groups2[i]); } + free(groups2); } } -- NSS Wrapper Repository