-/*
- * If a pthread setname/set_name function is available, declare
- * the setustprocname() function that will add '-ust' to the end
- * of the current process name, while truncating it if needed.
- */
-#if defined(HAVE_PTHREAD_SETNAME_NP) || defined(HAVE_PTHREAD_SETNAME_NP)
-#define LTTNG_UST_PROCNAME_SUFFIX "-ust"
-
-#include <pthread.h>
+static inline
+void lttng_ust_getprocname(char *name)
+{
+ lttng_pthread_getname_np(name, LTTNG_UST_PROCNAME_LEN);
+}