From e58be0f3425fb3e946a222077672c3c01308f887 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Tue, 23 Sep 2008 10:01:30 +0930 Subject: [PATCH] config: print error code if NIDR fails. --- config/hal.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/config/hal.c b/config/hal.c index 3e0ff0895..6573efed3 100644 --- a/config/hal.c +++ b/config/hal.c @@ -174,6 +174,7 @@ device_added(LibHalContext *hal_ctx, const char *udi) DeviceIntPtr dev = NULL; DBusError error; struct xkb_options xkb_opts = {0}; + int rc; LibHalPropertySet *set = NULL; LibHalPropertySetIterator set_iter; @@ -372,8 +373,8 @@ device_added(LibHalContext *hal_ctx, const char *udi) /* this isn't an error, but how else do you output something that the user can see? */ LogMessage(X_INFO, "config/hal: Adding input device %s\n", name); - if (NewInputDeviceRequest(options, &dev) != Success) { - LogMessage(X_ERROR, "config/hal: NewInputDeviceRequest failed\n"); + if ((rc = NewInputDeviceRequest(options, &dev)) != Success) { + LogMessage(X_ERROR, "config/hal: NewInputDeviceRequest failed (%d)\n", rc); dev = NULL; goto unwind; }