From 636dda476734869c0e1fbf4d0464779a4c6fe667 Mon Sep 17 00:00:00 2001 From: Rui Matos Date: Thu, 12 Jul 2012 11:11:23 -0400 Subject: [PATCH] bus: Own a name on the DBus session bus This makes it easier for third parties to track the ibus-daemon life cycle. BUG=http://code.google.com/p/ibus/issues/detail?id=1476 TEST= Review URL: https://codereview.appspot.com/6374058 Patch from Rui Matos . --- bus/server.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bus/server.c b/bus/server.c index ed38460..253b6c3 100644 --- a/bus/server.c +++ b/bus/server.c @@ -122,6 +122,10 @@ bus_server_init (void) /* write address to file */ ibus_write_address (address); + + /* own a session bus name so that third parties can easily track our life-cycle */ + g_bus_own_name (G_BUS_TYPE_SESSION, IBUS_SERVICE_IBUS, G_BUS_NAME_OWNER_FLAGS_NONE, + NULL, NULL, NULL, NULL, NULL); } const gchar * -- 2.7.4