summaryrefslogtreecommitdiff
path: root/gui/simple-greeter/greeter-main.c
diff options
context:
space:
mode:
authorWilliam Jon McCann <mccann@jhu.edu>2007-10-23 23:08:25 +0000
committerWilliam Jon McCann <mccann@src.gnome.org>2007-10-23 23:08:25 +0000
commit1b7a77cc35400f22775ae829b711f77089a59c26 (patch)
treee24da3a3ae5e8e07a46b5a04ec97cc035ca91633 /gui/simple-greeter/greeter-main.c
parent2a2a4532c0895f8884490bb05749db5424488a69 (diff)
downloadgdm-1b7a77cc35400f22775ae829b711f77089a59c26.tar.gz
More refactoring. Change gdm-greeter.c to be just a window. Make greeter
2007-10-23 William Jon McCann <mccann@jhu.edu> * gui/simple-greeter/Makefile.am: * gui/simple-greeter/gdm-greeter-client.c: (gdm_greeter_client_get_display_is_local), (cache_display_values), (gdm_greeter_client_start), (gdm_greeter_client_class_init): * gui/simple-greeter/gdm-greeter-client.h: * gui/simple-greeter/gdm-greeter-login-window.c: (set_busy), (set_ready), (set_sensitive), (set_focus), (set_message), (switch_page), (do_cancel), (reset_dialog), (gdm_greeter_login_window_ready), (gdm_greeter_login_window_reset), (gdm_greeter_login_window_info), (gdm_greeter_login_window_problem), (gdm_greeter_login_window_info_query), (gdm_greeter_login_window_secret_info_query), (_gdm_greeter_login_window_set_display_is_local), (gdm_greeter_login_window_set_property), (gdm_greeter_login_window_get_property), (log_in_button_clicked), (cancel_button_clicked), (on_user_activated), (create_greeter), (gdm_greeter_login_window_constructor), (gdm_greeter_login_window_class_init), (gdm_greeter_login_window_init), (gdm_greeter_login_window_finalize), (gdm_greeter_login_window_new): * gui/simple-greeter/gdm-greeter-login-window.h: * gui/simple-greeter/gdm-greeter-session.c: (on_info), (on_problem), (on_ready), (on_reset), (on_info_query), (on_secret_info_query), (on_begin_verification), (on_query_answer), (on_select_session), (on_select_language), (on_select_user), (on_select_hostname), (on_cancelled), (on_disconnected), (start_login_window), (stop_login_window), (launch_compiz), (launch_metacity), (start_panel), (start_background), (start_window_manager), (gdm_greeter_session_set_level), (gdm_greeter_session_goto_level), (gdm_greeter_session_start), (gdm_greeter_session_init): * gui/simple-greeter/gdm-simple-greeter.c: * gui/simple-greeter/gdm-simple-greeter.glade: * gui/simple-greeter/gdm-simple-greeter.h: * gui/simple-greeter/greeter-main.c: (set_fatal_warnings), (main): More refactoring. Change gdm-greeter.c to be just a window. Make greeter warnings fatal in development releases. svn path=/trunk/; revision=5394
Diffstat (limited to 'gui/simple-greeter/greeter-main.c')
-rw-r--r--gui/simple-greeter/greeter-main.c26
1 files changed, 25 insertions, 1 deletions
diff --git a/gui/simple-greeter/greeter-main.c b/gui/simple-greeter/greeter-main.c
index 520e8768..7bc58a86 100644
--- a/gui/simple-greeter/greeter-main.c
+++ b/gui/simple-greeter/greeter-main.c
@@ -21,6 +21,7 @@
#include <stdlib.h>
#include <locale.h>
+#include <unistd.h>
#include <glib.h>
#include <glib/gi18n.h>
@@ -32,6 +33,23 @@
#include "gdm-greeter-session.h"
+static void
+set_fatal_warnings (void)
+{
+ char **versions;
+
+ versions = g_strsplit (VERSION, ".", 3);
+ if (versions && versions [0] && versions [1]) {
+ int major;
+ major = atoi (versions [1]);
+ if ((major % 2) != 0) {
+ g_setenv ("G_DEBUG", "fatal_warnings", FALSE);
+ g_log_set_always_fatal (G_LOG_LEVEL_WARNING);
+ }
+ }
+ g_strfreev (versions);
+}
+
int
main (int argc, char *argv[])
{
@@ -45,16 +63,22 @@ main (int argc, char *argv[])
setlocale (LC_ALL, "");
+ set_fatal_warnings ();
+
g_type_init ();
if (! gdm_settings_client_init (GDMCONFDIR "/gdm.schemas", "/")) {
exit (1);
}
- g_debug ("Greeter session for display %s xauthority:%s",
+ g_debug ("Greeter session pid=%d display=%s xauthority=%s",
+ (int)getpid (),
g_getenv ("DISPLAY"),
g_getenv ("XAUTHORITY"));
+ /* FIXME: For testing to make it easier to attach gdb */
+ sleep (15);
+
gdm_log_init ();
gdm_log_set_debug (TRUE);