From f041360ac17bc032c7e5a4553372893e42ba68c6 Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Fri, 15 Dec 2017 10:07:03 +0100 Subject: Check for prctl portability --- src/Utils.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/Utils.cpp') diff --git a/src/Utils.cpp b/src/Utils.cpp index cd116c7..f423dc1 100644 --- a/src/Utils.cpp +++ b/src/Utils.cpp @@ -27,7 +27,9 @@ #include "Utils.h" #include "GainControl.h" -#include +#if defined(HAVE_PRCTL) +# include +#endif #include static void printHeader() @@ -160,7 +162,9 @@ int set_realtime_prio(int prio) void set_thread_name(const char *name) { +#if defined(HAVE_PRCTL) prctl(PR_SET_NAME,name,0,0,0); +#endif } double parseChannel(const std::string& chan) -- cgit v1.2.3