From f8f320894357278a23fef2707edf6270a9093d72 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Wed, 29 Jan 2014 14:21:21 +0000 Subject: [PATCH 1/2] Comment that the first bus name we take is an initialization mutex We need a mutex that will protect our account migration process from other copies of MC running in parallel. If we don't take the "main" name until later, then that name can't be our mutex. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=24000 --- src/mcd-service.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/mcd-service.c b/src/mcd-service.c index 17c94b0..cf3d05e 100644 --- a/src/mcd-service.c +++ b/src/mcd-service.c @@ -133,6 +133,10 @@ mcd_service_constructed (GObject *obj) { DEBUG ("called"); + /* It's actually quite important that we request *a* bus name here, + * so we can use it as a mutex for loading and migrating accounts, + * all of which we want to have finished before we open up our main + * D-Bus API for business. (See also fd.o #24000) */ mcd_service_obtain_bus_name (MCD_OBJECT (obj)); mcd_debug_print_tree (obj); -- 1.9.rc1