From: Jan Djärv Date: Tue, 21 Mar 2006 14:39:41 +0000 (+0000) Subject: * xterm.c: x_session_initialized new variable. X-Git-Tag: emacs-pretest-22.0.90~3474 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=11e887e29ed7373ecda47ae4956c1752b47c8c98;p=emacs.git * xterm.c: x_session_initialized new variable. (x_term_init): Use x_session_initialized to check if x_session_initialize should be called. (x_initialize): Initialize x_session_initialized. --- diff --git a/src/ChangeLog b/src/ChangeLog index e208614b156..d699b23f059 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2006-03-21 Jan Dj,Ad(Brv + + * xterm.c: x_session_initialized new variable. + (x_term_init): Use x_session_initialized to check if + x_session_initialize should be called. + (x_initialize): Initialize x_session_initialized. + 2006-03-21 Kim F. Storm * fringe.c (draw_fringe_bitmap): Don't calculate default overlay arrow diff --git a/src/xterm.c b/src/xterm.c index 298b1c2e63d..82f3565f6c4 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -10039,6 +10039,10 @@ static XrmOptionDescRec emacs_options[] = { static int x_initialized; +#ifdef HAVE_X_SM +static int x_session_initialized; +#endif + #ifdef MULTI_KBOARD /* Test whether two display-name strings agree up to the dot that separates the screen number from the server number. */ @@ -10607,7 +10611,7 @@ x_term_init (display_name, xrm_option, resource_name) #ifdef HAVE_X_SM /* Only do this for the first display. */ - if (x_initialized == 1) + if (!x_session_initialized++) x_session_initialize (dpyinfo); #endif @@ -10792,6 +10796,9 @@ x_initialize () last_tool_bar_item = -1; any_help_event_p = 0; ignore_next_mouse_click_timeout = 0; +#ifdef HAVE_X_SM + x_session_initialized = 0; +#endif #ifdef USE_GTK current_count = -1;