jkunstle / rpms / vim

Forked from rpms/vim 3 years ago
Clone

Blame SOURCES/7.4.493

073263
To: vim_dev@googlegroups.com
073263
Subject: Patch 7.4.493
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.493
073263
Problem:    A TextChanged autocommand is triggered when saving a file.
073263
	    (William Gardner)
073263
Solution:   Update last_changedtick after calling unchanged(). (Christian
073263
	    Brabandt)
073263
Files:	    src/fileio.c
073263
073263
073263
*** ../vim-7.4.492/src/fileio.c	2014-09-23 15:45:04.870801055 +0200
073263
--- src/fileio.c	2014-10-31 19:48:35.030702344 +0100
073263
***************
073263
*** 4877,4882 ****
073263
--- 4877,4889 ----
073263
  	    )
073263
      {
073263
  	unchanged(buf, TRUE);
073263
+ #ifdef FEAT_AUTOCMD
073263
+ 	/* buf->b_changedtick is always incremented in unchanged() but that
073263
+ 	 * should not trigger a TextChanged event. */
073263
+ 	if (last_changedtick + 1 == buf->b_changedtick
073263
+ 					       && last_changedtick_buf == buf)
073263
+ 	    last_changedtick = buf->b_changedtick;
073263
+ #endif
073263
  	u_unchanged(buf);
073263
  	u_update_save_nr(buf);
073263
      }
073263
*** ../vim-7.4.492/src/version.c	2014-10-31 19:20:30.782742928 +0100
073263
--- src/version.c	2014-10-31 19:48:53.590701897 +0100
073263
***************
073263
*** 743,744 ****
073263
--- 743,746 ----
073263
  {   /* Add new patch number below this line */
073263
+ /**/
073263
+     493,
073263
  /**/
073263
073263
-- 
073263
You know you use Vim too much when you have this alias in your
073263
~/.bashrc file: alias :e=/bin/vim             (Eljay Love-Jensen)
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    ///