summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRay Strode <rstrode@redhat.com>2015-02-18 13:44:33 -0500
committerRay Strode <rstrode@redhat.com>2015-02-18 14:14:08 -0500
commit51c36a170eeae28a5093c0d8f55793fee22ac283 (patch)
tree44c36d48a28fbc21587b4a497cee4751082cddbd
parentfdaa1e72d87486c2bf4448f6d7145497b8400a8e (diff)
downloadgnome-session-51c36a170eeae28a5093c0d8f55793fee22ac283.tar.gz
manager: handle autorestart app death before registration
Right now we rely on autorestart apps to get their death handled when they disconnect from the bus. This only works if they've registered, though. This commit makes sure the restart_app codepath gets called for autorestart apps even if they haven't registered yet. (This commit makes gnome-session exit if the display server couldn't be started) https://bugzilla.gnome.org/show_bug.cgi?id=744752
-rw-r--r--gnome-session/gsm-manager.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gnome-session/gsm-manager.c b/gnome-session/gsm-manager.c
index 633045b9..775873fb 100644
--- a/gnome-session/gsm-manager.c
+++ b/gnome-session/gsm-manager.c
@@ -637,7 +637,7 @@ app_died (GsmApp *app,
{
g_warning ("Application '%s' killed by signal %d", gsm_app_peek_app_id (app), signal);
- if (gsm_app_peek_autorestart (app)) {
+ if (gsm_app_get_registered (app) && gsm_app_peek_autorestart (app)) {
g_debug ("Component '%s' is autorestart, ignoring died signal",
gsm_app_peek_app_id (app));
return;
@@ -667,7 +667,7 @@ app_exited (GsmApp *app,
/* Consider that non-success exit status means "crash" for required components */
if (exit_code != 0 && is_app_required (manager, app)) {
- if (gsm_app_peek_autorestart (app)) {
+ if (gsm_app_get_registered (app) && gsm_app_peek_autorestart (app)) {
g_debug ("Component '%s' is autorestart, ignoring non-successful exit",
gsm_app_peek_app_id (app));
return;