[banshee] GnomeBackend: Be more robust against GConf failures (bgo#659841)
- From: Bertrand Lorentz <blorentz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [banshee] GnomeBackend: Be more robust against GConf failures (bgo#659841)
- Date: Tue, 1 Nov 2011 14:58:48 +0000 (UTC)
commit 4ecc45539aa584775754e7a15033e6400d6b613d
Author: Bertrand Lorentz <bertrand lorentz gmail com>
Date: Tue Nov 1 15:51:50 2011 +0100
GnomeBackend: Be more robust against GConf failures (bgo#659841)
Wrap the call to GConf.Client.Set in a try/catch to work around a
bug in GConf 3.2.0 (bgo#659835). This prevents Banshee from going
haywire if the GConf daemon is not available because of that bug.
.../GConfConfigurationClient.cs | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/src/Backends/Banshee.Gnome/Banshee.GnomeBackend/GConfConfigurationClient.cs b/src/Backends/Banshee.Gnome/Banshee.GnomeBackend/GConfConfigurationClient.cs
index 9372b6f..42a2045 100644
--- a/src/Backends/Banshee.Gnome/Banshee.GnomeBackend/GConfConfigurationClient.cs
+++ b/src/Backends/Banshee.Gnome/Banshee.GnomeBackend/GConfConfigurationClient.cs
@@ -135,7 +135,13 @@ namespace Banshee.GnomeBackend
client = new GConf.Client ();
}
- client.Set (CreateKey (@namespace, key), value);
+ // We wrap the Set call in a try/catch to work around bgo#659835,
+ // which causes Banshee to go haywire (see bgo#659841)
+ try {
+ client.Set (CreateKey (@namespace, key), value);
+ } catch (Exception e) {
+ Log.Exception (String.Format ("Could not set GConf key {0}.{1}.", @namespace, key), e);
+ }
}
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]