From fa7b70a9b895789ec57562bbba0bc052fc91d134 Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Tue, 14 Jun 2016 17:36:16 -0700 Subject: [PATCH] kdrive: Only enable threaded input if we have input devices When there aren't any devices, the input thread is going to be pretty lonely, so don't bother to even start it. Signed-off-by: Keith Packard Reviewed-by: Peter Hutterer Signed-off-by: Peter Hutterer --- hw/kdrive/src/kinput.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/kdrive/src/kinput.c b/hw/kdrive/src/kinput.c index c2fc7bb8c..6ee575cf7 100644 --- a/hw/kdrive/src/kinput.c +++ b/hw/kdrive/src/kinput.c @@ -1305,7 +1305,8 @@ KdInitInput(void) KdKeyboardInfo *ki; struct KdConfigDevice *dev; - InputThreadPreInit(); + if (kdConfigPointers || kdConfigKeyboards) + InputThreadPreInit(); kdInputEnabled = TRUE;