From 02e3713cf1ff124cd4137f5e1ac617bf95005a5f Mon Sep 17 00:00:00 2001 From: Nicolas Dufresne Date: Tue, 30 Oct 2018 16:20:39 +0000 Subject: [PATCH] rtkit: Allow disabling with DISABLE_RTKIT Allow disabling real time thread, this is useful to run inside valgrind without being killed. Signed-off-by: Nicolas Dufresne --- src/modules/module-rtkit.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/modules/module-rtkit.c b/src/modules/module-rtkit.c index 981839abe..299e3c696 100644 --- a/src/modules/module-rtkit.c +++ b/src/modules/module-rtkit.c @@ -274,6 +274,9 @@ int pw_rtkit_make_realtime(struct pw_rtkit_bus *connection, pid_t thread, int pr DBusError error; int ret; + if (getenv("DISABLE_RTKIT")) + return -EPERM; + dbus_error_init(&error); if (thread == 0)