]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
updated for version 7.3.508 v7.3.508
authorBram Moolenaar <Bram@vim.org>
Wed, 25 Apr 2012 16:24:29 +0000 (18:24 +0200)
committerBram Moolenaar <Bram@vim.org>
Wed, 25 Apr 2012 16:24:29 +0000 (18:24 +0200)
Problem:    Default for v:register is not set.
Solution:   Init v:register in eval_init(). Correct for 'clipboard' before the
            main loop. (Ingo Karkat)

src/eval.c
src/main.c
src/version.c

index 33b1947570873939cf3896530e7322138582180a..4d45ae2574091caf8c6585e2ebe562a5a7e3212b 100644 (file)
@@ -880,6 +880,7 @@ eval_init()
            hash_add(&compat_hashtab, p->vv_di.di_key);
     }
     set_vim_var_nr(VV_SEARCHFORWARD, 1L);
+    set_reg_var(0);  /* default for v:register is not 0 but '"' */
 
 #ifdef EBCDIC
     /*
index 1a7e7b1feb3782bc9ad6842cfec84c3ebc76323d..e1573a0dfb69fc88cb6fe3f2114f5040bc527883 100644 (file)
@@ -928,6 +928,18 @@ int vim_main2(int argc, char **argv)
     TIME_MSG("VimEnter autocommands");
 #endif
 
+#if defined(FEAT_EVAL) && defined(FEAT_CLIPBOARD)
+    /* Adjust default register name for "unnamed" in 'clipboard'. Can only be
+     * done after the clipboard is available and all initial commands that may
+     * modify the 'clipboard' setting have run; i.e. just before entering the
+     * main loop. */
+    {
+       int default_regname = 0;
+       adjust_clip_reg(&default_regname);
+       set_reg_var(default_regname);
+    }
+#endif
+
 #if defined(FEAT_DIFF) && defined(FEAT_SCROLLBIND)
     /* When a startup script or session file setup for diff'ing and
      * scrollbind, sync the scrollbind now. */
@@ -1357,7 +1369,7 @@ getout(exitval)
                {
                    apply_autocmds(EVENT_BUFWINLEAVE, buf->b_fname,
                                                    buf->b_fname, FALSE, buf);
-                   buf->b_changedtick = -1;    /* note that we did it already */
+                   buf->b_changedtick = -1;  /* note that we did it already */
                    /* start all over, autocommands may mess up the lists */
                    next_tp = first_tabpage;
                    break;
index f4ef82523f7dd3ff29b8be29649254dd69f74b6d..7e77f9a83b047bc335f8ae49b80aa732e6dbc43e 100644 (file)
@@ -714,6 +714,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    508,
 /**/
     507,
 /**/