summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Withnall <philip.withnall@collabora.co.uk>2013-11-13 16:22:53 +0000
committerPhilip Withnall <philip@tecnocode.co.uk>2014-02-16 23:52:31 +0000
commitf880acf39c0f396c992da70c1b6eb2b353882c1d (patch)
treea60c758c3925d3e8b7f8988f73c60164764ff2bc
parent8a5f2890f4a60a9605de5624bc57a0344633684e (diff)
bluez: Don’t warn about the store being offline
If the Bluetooth device is disconnected by the user between updates of the contact metadata, the code previously printed a warning when the next update attempt failed. Instead, just gracefully and silently fail and schedule the next update. https://bugzilla.gnome.org/show_bug.cgi?id=712274
-rw-r--r--backends/bluez/bluez-persona-store.vala13
1 files changed, 11 insertions, 2 deletions
diff --git a/backends/bluez/bluez-persona-store.vala b/backends/bluez/bluez-persona-store.vala
index e1be0abc..b6a0f6e2 100644
--- a/backends/bluez/bluez-persona-store.vala
+++ b/backends/bluez/bluez-persona-store.vala
@@ -933,8 +933,17 @@ public class Folks.Backends.BlueZ.PersonaStore : Folks.PersonaStore
if (e4 is IOError.CANCELLED)
return;
- warning ("Error updating persona store from BlueZ: %s",
- e4.message);
+ /* Don't warn about offline stores. */
+ if (e4 is PersonaStoreError.STORE_OFFLINE)
+ {
+ debug ("Not updating persona store from BlueZ due to " +
+ "store being offline: %s", e4.message);
+ }
+ else
+ {
+ warning ("Error updating persona store from BlueZ: %s",
+ e4.message);
+ }
}
});