Changeset f4f275f for patches


Ignore:
Timestamp:
Jun 22, 2006, 11:13:09 AM (18 years ago)
Author:
Jim Gifford <clfs@…>
Branches:
clfs-1.2, clfs-2.1, clfs-3.0.0-systemd, clfs-3.0.0-sysvinit, master, systemd, sysvinit
Children:
bc36ca5
Parents:
22c3582
Message:

Updated Vim 7.0 patch

File:
1 moved

Legend:

Unmodified
Added
Removed
  • patches/vim-7.0-fixes-5.patch

    r22c3582 rf4f275f  
    11Submitted By: Jim Gifford (jim at linuxfromscratch dot org)
    2 Date: 2006-06-21
     2Date: 2006-06-22
    33Initial Package Version: 7.0
    44Origin: Upstream
    55Upstream Status: Applied
    6 Description: Contains Patch 001-004 and 006-022 from Upstream
    7         005 is for the extras and Windows 32 only
     6Description: Contains Patch 001-004, 006-026, and 028 from Upstream
     7        005 and 027 is for the extras and Windows 32 only
    88
    99diff -Naur vim70.orig/runtime/autoload/ccomplete.vim vim70/runtime/autoload/ccomplete.vim
     
    110110diff -Naur vim70.orig/src/edit.c vim70/src/edit.c
    111111--- vim70.orig/src/edit.c       2006-05-07 04:48:51.000000000 -0700
    112 +++ vim70/src/edit.c    2006-06-21 23:50:50.000000000 -0700
    113 @@ -751,7 +751,7 @@
     112+++ vim70/src/edit.c    2006-06-22 11:03:06.000000000 -0700
     113@@ -719,9 +719,14 @@
     114 #ifdef FEAT_INS_EXPAND
     115        /*
     116         * Special handling of keys while the popup menu is visible or wanted
     117-        * and the cursor is still in the completed word.
     118+        * and the cursor is still in the completed word.  Only when there is
     119+        * a match, skip this when no matches were found.
     120         */
     121-       if (compl_started && pum_wanted() && curwin->w_cursor.col >= compl_col)
     122+       if (compl_started
     123+               && pum_wanted()
     124+               && curwin->w_cursor.col >= compl_col
     125+               && (compl_shown_match == NULL
     126+                   || compl_shown_match != compl_shown_match->cp_next))
     127        {
     128            /* BS: Delete one character from "compl_leader". */
     129            if ((c == K_BS || c == Ctrl_H)
     130@@ -751,7 +756,7 @@
    114131                    continue;
    115132                }
     
    120137                if (c == Ctrl_Y || (compl_enter_selects
    121138                                   && (c == CAR || c == K_KENTER || c == NL)))
    122 @@ -3046,7 +3046,6 @@
     139@@ -3046,7 +3051,6 @@
    123140     ins_compl_delete();
    124141     ins_bytes(compl_leader + curwin->w_cursor.col - compl_col);
     
    128145     if (compl_started)
    129146        ins_compl_set_original_text(compl_leader);
    130 @@ -3076,6 +3075,7 @@
     147@@ -3076,6 +3080,7 @@
    131148        compl_restarting = FALSE;
    132149     }
     
    136153     {
    137154        /* Go to the original text, since none of the matches is inserted. */
    138 @@ -3087,6 +3087,8 @@
     155@@ -3087,6 +3092,8 @@
    139156        compl_curr_match = compl_shown_match;
    140157        compl_shows_dir = compl_direction;
     
    145162     /* Show the popup menu with a different set of matches. */
    146163     ins_compl_show_pum();
    147 @@ -3175,10 +3177,32 @@
     164@@ -3175,10 +3182,32 @@
    148165     char_u     *p;
    149166     int                len = curwin->w_cursor.col - compl_col;
     
    179196 #ifdef FEAT_MBYTE
    180197     c = mb_ptr2char(p);
    181 @@ -4100,6 +4124,21 @@
     198@@ -3369,16 +3398,21 @@
     199                    ptr = compl_leader;
     200                else
     201                    ptr = compl_orig_text;
     202-               p = compl_orig_text;
     203-               for (temp = 0; p[temp] != NUL && p[temp] == ptr[temp]; ++temp)
     204-                   ;
     205+               if (compl_orig_text != NULL)
     206+               {
     207+                   p = compl_orig_text;
     208+                   for (temp = 0; p[temp] != NUL && p[temp] == ptr[temp];
     209+                                                                      ++temp)
     210+                       ;
     211 #ifdef FEAT_MBYTE
     212-               if (temp > 0)
     213-                   temp -= (*mb_head_off)(compl_orig_text, p + temp);
     214+                   if (temp > 0)
     215+                       temp -= (*mb_head_off)(compl_orig_text, p + temp);
     216 #endif
     217-               for (p += temp; *p != NUL; mb_ptr_adv(p))
     218-                   AppendCharToRedobuff(K_BS);
     219-               AppendToRedobuffLit(ptr + temp, -1);
     220+                   for (p += temp; *p != NUL; mb_ptr_adv(p))
     221+                       AppendCharToRedobuff(K_BS);
     222+               }
     223+               if (ptr != NULL)
     224+                   AppendToRedobuffLit(ptr + temp, -1);
     225            }
     226 
     227 #ifdef FEAT_CINDENT
     228@@ -4100,6 +4134,21 @@
    182229                && compl_shown_match->cp_next != NULL
    183230                && compl_shown_match->cp_next != compl_first_match)
     
    201248 
    202249     if (allow_get_expansion && insert_match
     250@@ -4611,10 +4660,18 @@
     251                                     (int)STRLEN(compl_pattern), curs_col);
     252            if (compl_xp.xp_context == EXPAND_UNSUCCESSFUL
     253                    || compl_xp.xp_context == EXPAND_NOTHING)
     254-               return FAIL;
     255-           startcol = (int)(compl_xp.xp_pattern - compl_pattern);
     256-           compl_col = startcol;
     257-           compl_length = curs_col - startcol;
     258+           {
     259+               compl_col = curs_col;
     260+               compl_length = 0;
     261+               vim_free(compl_pattern);
     262+               compl_pattern = NULL;
     263+           }
     264+           else
     265+           {
     266+               startcol = (int)(compl_xp.xp_pattern - compl_pattern);
     267+               compl_col = startcol;
     268+               compl_length = curs_col - startcol;
     269+           }
     270        }
     271        else if (ctrl_x_mode == CTRL_X_FUNCTION || ctrl_x_mode == CTRL_X_OMNI)
     272        {
     273@@ -4668,11 +4725,17 @@
     274            else
     275                compl_col = spell_word_start(startcol);
     276            if (compl_col >= (colnr_T)startcol)
     277-               return FAIL;
     278-           spell_expand_check_cap(compl_col);
     279+           {
     280+               compl_length = 0;
     281+               compl_col = curs_col;
     282+           }
     283+           else
     284+           {
     285+               spell_expand_check_cap(compl_col);
     286+               compl_length = (int)curs_col - compl_col;
     287+           }
     288            /* Need to obtain "line" again, it may have become invalid. */
     289            line = ml_get(curwin->w_cursor.lnum);
     290-           compl_length = (int)curs_col - compl_col;
     291            compl_pattern = vim_strnsave(line + compl_col, compl_length);
     292            if (compl_pattern == NULL)
     293 #endif
    203294diff -Naur vim70.orig/src/eval.c vim70/src/eval.c
    204295--- vim70.orig/src/eval.c       2006-05-05 10:15:26.000000000 -0700
    205 +++ vim70/src/eval.c    2006-06-21 23:50:50.000000000 -0700
     296+++ vim70/src/eval.c    2006-06-22 11:03:59.000000000 -0700
    206297@@ -11372,7 +11372,7 @@
    207298            if (argvars[2].v_type != VAR_UNKNOWN)
     
    213304 
    214305                rettv->vval.v_string = NULL;
    215 @@ -18963,7 +18963,8 @@
     306@@ -13250,7 +13250,7 @@
     307        if (argvars[2].v_type != VAR_UNKNOWN)
     308            EMSG2(_(e_toomanyarg), "remove()");
     309        else if ((d = argvars[0].vval.v_dict) != NULL
     310-               && !tv_check_lock(d->dv_lock, (char_u *)"remove()"))
     311+               && !tv_check_lock(d->dv_lock, (char_u *)"remove() argument"))
     312        {
     313            key = get_tv_string_chk(&argvars[1]);
     314            if (key != NULL)
     315@@ -13270,7 +13270,7 @@
     316     else if (argvars[0].v_type != VAR_LIST)
     317        EMSG2(_(e_listdictarg), "remove()");
     318     else if ((l = argvars[0].vval.v_list) != NULL
     319-           && !tv_check_lock(l->lv_lock, (char_u *)"remove()"))
     320+           && !tv_check_lock(l->lv_lock, (char_u *)"remove() argument"))
     321     {
     322        int         error = FALSE;
     323 
     324@@ -17759,6 +17759,13 @@
     325     }
     326     else                   /* add a new variable */
     327     {
     328+       /* Can't add "v:" variable. */
     329+       if (ht == &vimvarht)
     330+       {
     331+           EMSG2(_(e_illvar), name);
     332+           return;
     333+       }
     334+
     335        /* Make sure the variable name is valid. */
     336        for (p = varname; *p != NUL; ++p)
     337            if (!eval_isnamec1(*p) && (p == varname || !VIM_ISDIGIT(*p))
     338@@ -18963,7 +18970,8 @@
    216339     else if (lead > 0)
    217340     {
     
    223346            /* It's "s:" or "<SID>" */
    224347            if (current_SID <= 0)
     348@@ -19685,6 +19693,7 @@
     349     v->di_tv.vval.v_list = &fc.l_varlist;
     350     vim_memset(&fc.l_varlist, 0, sizeof(list_T));
     351     fc.l_varlist.lv_refcount = 99999;
     352+    fc.l_varlist.lv_lock = VAR_FIXED;
     353 
     354     /*
     355      * Set a:firstline to "firstline" and a:lastline to "lastline".
    225356diff -Naur vim70.orig/src/ex_docmd.c vim70/src/ex_docmd.c
    226357--- vim70.orig/src/ex_docmd.c   2006-05-05 09:33:19.000000000 -0700
     
    744875            case PV_INDE:       return &curbuf->b_p_inde_flags;
    745876 # endif
     877diff -Naur vim70.orig/src/os_unix.c vim70/src/os_unix.c
     878--- vim70.orig/src/os_unix.c    2006-05-01 01:13:15.000000000 -0700
     879+++ vim70/src/os_unix.c 2006-06-22 11:06:09.000000000 -0700
     880@@ -4971,7 +4971,8 @@
     881                    if (((*file)[*num_file] = alloc(len + 2)) != NULL)
     882                    {
     883                        STRCPY((*file)[*num_file], p);
     884-                       if (!after_pathsep((*file)[*num_file] + len))
     885+                       if (!after_pathsep((*file)[*num_file],
     886+                                                   (*file)[*num_file] + len))
     887                        {
     888                            (*file)[*num_file][len] = psepc;
     889                            (*file)[*num_file][len + 1] = NUL;
     890@@ -5757,8 +5758,13 @@
     891     int                retval_int = 0;
     892     int                success = FALSE;
     893 
     894-    /* Get a handle to the DLL module. */
     895+    /*
     896+     * Get a handle to the DLL module.
     897+     */
     898 # if defined(USE_DLOPEN)
     899+    /* First clear any error, it's not cleared by the dlopen() call. */
     900+    (void)dlerror();
     901+
     902     hinstLib = dlopen((char *)libname, RTLD_LAZY
     903 #  ifdef RTLD_LOCAL
     904            | RTLD_LOCAL
    746905diff -Naur vim70.orig/src/quickfix.c vim70/src/quickfix.c
    747906--- vim70.orig/src/quickfix.c   2006-05-03 00:47:42.000000000 -0700
     
    8481007diff -Naur vim70.orig/src/version.c vim70/src/version.c
    8491008--- vim70.orig/src/version.c    2006-05-03 00:50:42.000000000 -0700
    850 +++ vim70/src/version.c 2006-06-21 23:56:28.000000000 -0700
    851 @@ -667,6 +667,48 @@
     1009+++ vim70/src/version.c 2006-06-22 11:06:13.000000000 -0700
     1010@@ -667,6 +667,58 @@
    8521011 static int included_patches[] =
    8531012 {   /* Add new patch number below this line */
    8541013 /**/
     1014+    28,
     1015+/**/
     1016+    26,
     1017+/**/
     1018+    25,
     1019+/**/
     1020+    24,
     1021+/**/
     1022+    23,
     1023+/**/
    8551024+    22,
    8561025+/**/
     
    8981067 };
    8991068 
    900  
     1069diff -Naur vim70.orig/src/vim.h vim70/src/vim.h
     1070--- vim70.orig/src/vim.h        2006-04-30 08:32:38.000000000 -0700
     1071+++ vim70/src/vim.h     2006-06-22 11:06:09.000000000 -0700
     1072@@ -1983,7 +1983,7 @@
     1073 /* values for vim_handle_signal() that are not a signal */
     1074 #define SIGNAL_BLOCK   -1
     1075 #define SIGNAL_UNBLOCK  -2
     1076-#if !defined(UNIX) && !defined(VMS)
     1077+#if !defined(UNIX) && !defined(VMS) && !defined(OS2)
     1078 # define vim_handle_signal(x) 0
     1079 #endif
     1080 
     1081
Note: See TracChangeset for help on using the changeset viewer.