[folks] core: Don’t warn if a D-Bus service is mi ssing
- From: Philip Withnall <pwithnall src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [folks] core: Don’t warn if a D-Bus service is mi ssing
- Date: Thu, 30 Jan 2014 07:51:27 +0000 (UTC)
commit eac52ef741bade059d077bd149889accb40ab2af
Author: Philip Withnall <philip withnall collabora co uk>
Date: Thu Jan 30 07:49:29 2014 +0000
core: Don’t warn if a D-Bus service is missing
If a backend fails to start because a D-Bus service is missing, don’t
spew a warning into stderr. It probably means that the user is running
folks from git and has more development packages installed than services
running. Or it means that a distro packager has built too many backends
by default, rather than packaging them up separately and adding
dependencies on the relevant D-Bus packages.
In any case, it’s irrelevant, unnecessary debug spew.
folks/backend-store.vala | 16 ++++++++++++++--
1 files changed, 14 insertions(+), 2 deletions(-)
---
diff --git a/folks/backend-store.vala b/folks/backend-store.vala
index 0f47236..4af4d20 100644
--- a/folks/backend-store.vala
+++ b/folks/backend-store.vala
@@ -406,8 +406,20 @@ public class Folks.BackendStore : Object {
}
catch (GLib.Error e)
{
- warning ("Error preparing Backend '%s': %s",
- backend.name, e.message);
+ if (e is DBusError.SERVICE_UNKNOWN)
+ {
+ /* Don’t warn if a D-Bus service is unknown; it probably
+ * means the backend is deliberately not running and the
+ * user is running folks from git, so hasn’t appropriately
+ * enabled/disabled backends from building. */
+ debug ("Error preparing Backend '%s': %s",
+ backend.name, e.message);
+ }
+ else
+ {
+ warning ("Error preparing Backend '%s': %s",
+ backend.name, e.message);
+ }
}
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]