diff options
author | Lars Uebernickel <lars.uebernickel@canonical.com> | 2013-10-28 19:22:30 +0000 |
---|---|---|
committer | Tarmac <Unknown> | 2013-10-28 19:22:30 +0000 |
commit | 202050c3718fbe191aa52343a02c8c028e659401 (patch) | |
tree | 082a7dc13bbd86841431f3e420a009a50371452b /src | |
parent | 1322e98ab297bf69bd9b812a8d22ca8b373d7208 (diff) | |
parent | 6361bb3525cbcacb819128dd24eff2b7ec581c1a (diff) | |
download | ayatana-indicator-messages-202050c3718fbe191aa52343a02c8c028e659401.tar.gz ayatana-indicator-messages-202050c3718fbe191aa52343a02c8c028e659401.tar.bz2 ayatana-indicator-messages-202050c3718fbe191aa52343a02c8c028e659401.zip |
Protect against processes calling Register() multiple times
Don't unnecessarily reset the application's state if the same process calls Register() more than once.
Approved by Charles Kerr, PS Jenkins bot.
Diffstat (limited to 'src')
-rw-r--r-- | src/im-application-list.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/im-application-list.c b/src/im-application-list.c index 8e59dcb..d285fda 100644 --- a/src/im-application-list.c +++ b/src/im-application-list.c @@ -1163,9 +1163,12 @@ im_application_list_set_remote (ImApplicationList *list, if (app->proxy) name_owner = g_dbus_proxy_get_name_owner (G_DBUS_PROXY (app->proxy)); - g_warning ("replacing '%s' at %s with %s", id, name_owner, unique_bus_name); - im_application_list_unset_remote (app); + if (g_strcmp0 (name_owner, unique_bus_name) != 0) + { + g_warning ("replacing '%s' at %s with %s", id, name_owner, unique_bus_name); + im_application_list_unset_remote (app); + } g_free (name_owner); } |