Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/lib/dlt_user.c
Original file line number Diff line number Diff line change
Expand Up @@ -4835,8 +4835,13 @@ void *dlt_user_housekeeperthread_function(void *ptr)
#endif

#ifdef DLT_USE_PTHREAD_SETNAME_NP
#ifdef __APPLE__
if (pthread_setname_np("dlt_housekeeper"))
dlt_log(LOG_WARNING, "Failed to rename housekeeper thread!\n");
#else
if (pthread_setname_np(dlt_housekeeperthread_handle, "dlt_housekeeper"))
dlt_log(LOG_WARNING, "Failed to rename housekeeper thread!\n");
#endif
#elif linux
if (prctl(PR_SET_NAME, "dlt_housekeeper", 0, 0, 0) < 0)
dlt_log(LOG_WARNING, "Failed to rename housekeeper thread!\n");
Expand Down Expand Up @@ -7362,7 +7367,9 @@ int dlt_start_threads()
*/
pthread_condattr_t attr;
pthread_condattr_init(&attr);
#ifndef __APPLE__
pthread_condattr_setclock(&attr, CLOCK_MONOTONIC);
#endif
pthread_cond_init(&dlt_housekeeper_running_cond, &attr);

if (pthread_create(&(dlt_housekeeperthread_handle),
Expand Down
2 changes: 2 additions & 0 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ if("${CMAKE_SYSTEM_NAME}" MATCHES "Linux|CYGWIN")
set(LIBRARIES "")
elseif("${CMAKE_SYSTEM_NAME}" MATCHES "QNX")
set(LIBRARIES regex)
elseif("${CMAKE_SYSTEM_NAME}" MATCHES "Darwin")
set(LIBRARIES "")
else()
set(LIBRARIES socket)
endif()
Expand Down