From 1f24638985ce053b696ca3359cc50b5bc26ccb03 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Wed, 9 Sep 2009 09:28:46 +1000 Subject: [PATCH] kdrive: output meaningful error message for HAL devices. kdrive ignores all devices from hal as they don't have the 'type' option set. Instead of "Unrecognised device identifier!" print out "Ignoring device from HAL." to indicate that the errors surrounding the device don't really matter. Signed-off-by: Peter Hutterer Signed-off-by: Daniel Stone --- hw/kdrive/src/kinput.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/hw/kdrive/src/kinput.c b/hw/kdrive/src/kinput.c index 832b09c90..fb8ebd076 100644 --- a/hw/kdrive/src/kinput.c +++ b/hw/kdrive/src/kinput.c @@ -2272,6 +2272,14 @@ NewInputDeviceRequest(InputOption *options, DeviceIntPtr *pdev) return BadValue; } } +#ifdef CONFIG_HAL + else if (strcmp(option->key, "_source") == 0 && + strcmp(option->value, "server/hal") == 0) + { + ErrorF("Ignoring device from HAL.\n"); + return BadValue; + } +#endif } if (!ki && !pi) {