Changeset f4f275f
- Timestamp:
- Jun 22, 2006, 11:13:09 AM (19 years ago)
- Branches:
- clfs-1.2, clfs-2.1, clfs-3.0.0-systemd, clfs-3.0.0-sysvinit, master, systemd, sysvinit
- Children:
- bc36ca5
- Parents:
- 22c3582
- File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
patches/vim-7.0-fixes-5.patch
r22c3582 rf4f275f 1 1 Submitted By: Jim Gifford (jim at linuxfromscratch dot org) 2 Date: 2006-06-2 12 Date: 2006-06-22 3 3 Initial Package Version: 7.0 4 4 Origin: Upstream 5 5 Upstream Status: Applied 6 Description: Contains Patch 001-004 and 006-022from Upstream7 005 is for the extras and Windows 32 only6 Description: Contains Patch 001-004, 006-026, and 028 from Upstream 7 005 and 027 is for the extras and Windows 32 only 8 8 9 9 diff -Naur vim70.orig/runtime/autoload/ccomplete.vim vim70/runtime/autoload/ccomplete.vim … … 110 110 diff -Naur vim70.orig/src/edit.c vim70/src/edit.c 111 111 --- 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 @@ 114 131 continue; 115 132 } … … 120 137 if (c == Ctrl_Y || (compl_enter_selects 121 138 && (c == CAR || c == K_KENTER || c == NL))) 122 @@ -3046,7 +30 46,6 @@139 @@ -3046,7 +3051,6 @@ 123 140 ins_compl_delete(); 124 141 ins_bytes(compl_leader + curwin->w_cursor.col - compl_col); … … 128 145 if (compl_started) 129 146 ins_compl_set_original_text(compl_leader); 130 @@ -3076,6 +30 75,7 @@147 @@ -3076,6 +3080,7 @@ 131 148 compl_restarting = FALSE; 132 149 } … … 136 153 { 137 154 /* Go to the original text, since none of the matches is inserted. */ 138 @@ -3087,6 +30 87,8 @@155 @@ -3087,6 +3092,8 @@ 139 156 compl_curr_match = compl_shown_match; 140 157 compl_shows_dir = compl_direction; … … 145 162 /* Show the popup menu with a different set of matches. */ 146 163 ins_compl_show_pum(); 147 @@ -3175,10 +31 77,32 @@164 @@ -3175,10 +3182,32 @@ 148 165 char_u *p; 149 166 int len = curwin->w_cursor.col - compl_col; … … 179 196 #ifdef FEAT_MBYTE 180 197 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 @@ 182 229 && compl_shown_match->cp_next != NULL 183 230 && compl_shown_match->cp_next != compl_first_match) … … 201 248 202 249 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 203 294 diff -Naur vim70.orig/src/eval.c vim70/src/eval.c 204 295 --- vim70.orig/src/eval.c 2006-05-05 10:15:26.000000000 -0700 205 +++ vim70/src/eval.c 2006-06-2 1 23:50:50.000000000 -0700296 +++ vim70/src/eval.c 2006-06-22 11:03:59.000000000 -0700 206 297 @@ -11372,7 +11372,7 @@ 207 298 if (argvars[2].v_type != VAR_UNKNOWN) … … 213 304 214 305 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 @@ 216 339 else if (lead > 0) 217 340 { … … 223 346 /* It's "s:" or "<SID>" */ 224 347 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". 225 356 diff -Naur vim70.orig/src/ex_docmd.c vim70/src/ex_docmd.c 226 357 --- vim70.orig/src/ex_docmd.c 2006-05-05 09:33:19.000000000 -0700 … … 744 875 case PV_INDE: return &curbuf->b_p_inde_flags; 745 876 # endif 877 diff -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 746 905 diff -Naur vim70.orig/src/quickfix.c vim70/src/quickfix.c 747 906 --- vim70.orig/src/quickfix.c 2006-05-03 00:47:42.000000000 -0700 … … 848 1007 diff -Naur vim70.orig/src/version.c vim70/src/version.c 849 1008 --- vim70.orig/src/version.c 2006-05-03 00:50:42.000000000 -0700 850 +++ vim70/src/version.c 2006-06-2 1 23:56:28.000000000 -0700851 @@ -667,6 +667, 48 @@1009 +++ vim70/src/version.c 2006-06-22 11:06:13.000000000 -0700 1010 @@ -667,6 +667,58 @@ 852 1011 static int included_patches[] = 853 1012 { /* Add new patch number below this line */ 854 1013 /**/ 1014 + 28, 1015 +/**/ 1016 + 26, 1017 +/**/ 1018 + 25, 1019 +/**/ 1020 + 24, 1021 +/**/ 1022 + 23, 1023 +/**/ 855 1024 + 22, 856 1025 +/**/ … … 898 1067 }; 899 1068 900 1069 diff -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.