[banshee/stable] Fix NRE caused by Beroe not starting the preferences service (BGO #576033)
- From: Gabriel Burt <gburt src gnome org>
- To: svn-commits-list gnome org
- Subject: [banshee/stable] Fix NRE caused by Beroe not starting the preferences service (BGO #576033)
- Date: Tue, 19 May 2009 11:21:26 -0400 (EDT)
commit 138c67320e0cb5e4205f9541f135dc20f0fec847
Author: Alex Launi <alex launi gmail com>
Date: Tue May 19 10:16:21 2009 -0500
Fix NRE caused by Beroe not starting the preferences service (BGO #576033)
---
src/Clients/Beroe/Beroe/IndexerClient.cs | 2 ++
.../IndexerClient.cs | 9 +++++++--
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/src/Clients/Beroe/Beroe/IndexerClient.cs b/src/Clients/Beroe/Beroe/IndexerClient.cs
index 9dbb120..b3b5f7a 100644
--- a/src/Clients/Beroe/Beroe/IndexerClient.cs
+++ b/src/Clients/Beroe/Beroe/IndexerClient.cs
@@ -36,6 +36,7 @@ using Hyena;
using Banshee.Base;
using Banshee.Database;
+using Banshee.Preferences;
using Banshee.ServiceStack;
using Banshee.Sources;
using Banshee.Collection.Indexer;
@@ -78,6 +79,7 @@ namespace Beroe
ServiceManager.RegisterService<DBusServiceManager> ();
ServiceManager.RegisterService<BansheeDbConnection> ();
ServiceManager.RegisterService<SourceManager> ();
+ ServiceManager.RegisterService<PreferenceService> ();
ServiceManager.RegisterService<CollectionIndexerService> ();
ServiceManager.RegisterService<IndexerClient> ();
ServiceManager.Run ();
diff --git a/src/Core/Banshee.CollectionIndexer/Banshee.Collection.Indexer.RemoteHelper/IndexerClient.cs b/src/Core/Banshee.CollectionIndexer/Banshee.Collection.Indexer.RemoteHelper/IndexerClient.cs
index 3e5058c..3867fcc 100644
--- a/src/Core/Banshee.CollectionIndexer/Banshee.Collection.Indexer.RemoteHelper/IndexerClient.cs
+++ b/src/Core/Banshee.CollectionIndexer/Banshee.Collection.Indexer.RemoteHelper/IndexerClient.cs
@@ -112,8 +112,13 @@ namespace Banshee.Collection.Indexer.RemoteHelper
{
DisconnectFromIndexerService ();
ResolveIndexerService ();
-
- Debug ("Connected to {0}", service_interface);
+
+ if (service == null) {
+ Log.Error ("Failed to connect to {0}, bailing.", service_interface);
+ return;
+ } else {
+ Debug ("Connected to {0}", service_interface);
+ }
service.CleanupAndShutdown += OnCleanupAndShutdown;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]