From c4e18dbd69b9c01c73c5757c860ee8373bd3d071 Mon Sep 17 00:00:00 2001 From: walters Date: Sat, 22 Mar 2008 04:26:58 +0000 Subject: +2008-03-22 Colin Walters + + * MAINTAINERS: New file. + * src/krb5-auth-dialog.c: Connect to session bus + to be sure we exit when the session dies. + git-svn-id: http://svn.gnome.org/svn/krb5-auth-dialog/trunk@70 517b70f8-ed25-0410-8bf6-f5db08f7b76e --- src/krb5-auth-dialog.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src') diff --git a/src/krb5-auth-dialog.c b/src/krb5-auth-dialog.c index 1f29c32..36387a9 100644 --- a/src/krb5-auth-dialog.c +++ b/src/krb5-auth-dialog.c @@ -29,6 +29,7 @@ #include #include #include +#include #ifdef ENABLE_NETWORK_MANAGER @@ -570,6 +571,8 @@ main (int argc, char *argv[]) { GtkWidget *dialog; GnomeClient *client; + DBusGConnection *session; + GError *error = NULL; int run_auto = 0, run_always = 0; struct poptOption options[] = { {"auto", 'a', 0, &run_auto, 0, @@ -591,6 +594,9 @@ main (int argc, char *argv[]) client = gnome_master_client (); gnome_client_set_restart_style (client, GNOME_RESTART_ANYWAY); + /* Connect to the session bus so we get exit-on-disconnect semantics. */ + session = dbus_g_bus_get(DBUS_BUS_SESSION, &error); + if (run_always && !run_auto) { always_run++; } -- cgit v1.2.3