073263
To: vim_dev@googlegroups.com
073263
Subject: Patch 7.4.558
073263
Fcc: outbox
073263
From: Bram Moolenaar <Bram@moolenaar.net>
073263
Mime-Version: 1.0
073263
Content-Type: text/plain; charset=UTF-8
073263
Content-Transfer-Encoding: 8bit
073263
------------
073263
073263
Patch 7.4.558
073263
Problem:    When the X server restarts Vim may get stuck.
073263
Solution:   Destroy the application context and create it again.  (Issue 203)
073263
Files:	    src/os_unix.c
073263
073263
073263
*** ../vim-7.4.557/src/os_unix.c	2014-12-17 14:36:10.367090935 +0100
073263
--- src/os_unix.c	2014-12-17 17:55:23.187644328 +0100
073263
***************
073263
*** 1617,1622 ****
073263
--- 1617,1633 ----
073263
      if (xterm_dpy_was_reset)
073263
      {
073263
  	xterm_dpy_was_reset = FALSE;
073263
+ 
073263
+ # ifndef LESSTIF_VERSION
073263
+ 	/* This has been reported to avoid Vim getting stuck. */
073263
+ 	if (app_context != (XtAppContext)NULL)
073263
+ 	{
073263
+ 	    XtDestroyApplicationContext(app_context);
073263
+ 	    app_context = (XtAppContext)NULL;
073263
+ 	    x11_display = NULL; /* freed by XtDestroyApplicationContext() */
073263
+ 	}
073263
+ # endif
073263
+ 
073263
  	setup_term_clip();
073263
  	get_x11_title(FALSE);
073263
      }
073263
*** ../vim-7.4.557/src/version.c	2014-12-17 14:47:52.870412129 +0100
073263
--- src/version.c	2014-12-17 17:57:10.026323560 +0100
073263
***************
073263
*** 743,744 ****
073263
--- 743,746 ----
073263
  {   /* Add new patch number below this line */
073263
+ /**/
073263
+     558,
073263
  /**/
073263
073263
-- 
073263
hundred-and-one symptoms of being an internet addict:
073263
14. You start introducing yourself as "Jim at I-I-Net dot net dot au"
073263
073263
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
073263
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
073263
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
073263
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///