From 70a5fce8a4da9b9b000c86cd9c2ae668d1025850 Mon Sep 17 00:00:00 2001 From: Richard Hughes Date: Wed, 27 May 2009 15:47:06 +0100 Subject: Fix up the return statuses from coldplug and refresh, as different modules are doing different things --- src/dkp-hid.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/dkp-hid.c') diff --git a/src/dkp-hid.c b/src/dkp-hid.c index 4e4991b..374bd3f 100644 --- a/src/dkp-hid.c +++ b/src/dkp-hid.c @@ -281,6 +281,8 @@ dkp_hid_get_all_data (DkpHid *hid) /** * dkp_hid_coldplug: + * + * Return %TRUE on success, %FALSE if we failed to get data and should be removed **/ static gboolean dkp_hid_coldplug (DkpDevice *device) @@ -351,6 +353,8 @@ out: /** * dkp_hid_refresh: + * + * Return %TRUE on success, %FALSE if we failed to refresh or no data **/ static gboolean dkp_hid_refresh (DkpDevice *device) @@ -370,7 +374,7 @@ dkp_hid_refresh (DkpDevice *device) /* read any data -- it's okay if there's nothing as we are non-blocking */ rd = read (hid->priv->fd, ev, sizeof (ev)); if (rd < (int) sizeof (ev[0])) { - ret = TRUE; + ret = FALSE; goto out; } -- cgit v1.2.3