Changeset 1f22c7c
- Timestamp:
- Dec 31, 2008, 12:23:48 AM (16 years ago)
- Branches:
- clfs-1.2, clfs-2.1, clfs-3.0.0-systemd, clfs-3.0.0-sysvinit, master, systemd, sysvinit
- Children:
- 893ca261
- Parents:
- 06dcdf6
- Files:
-
- 2 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
BOOK/introduction/common/changelog.xml
r06dcdf6 r1f22c7c 36 36 </listitem> 37 37 --> 38 39 <listitem> 40 <para>December 30, 2008</para> 41 <itemizedlist> 42 <listitem> 43 <para>[Jim] - Updated Vim Patch to -3.</para> 44 </listitem> 45 </itemizedlist> 46 </listitem> 38 47 39 48 <listitem> -
BOOK/patches.ent
r06dcdf6 r1f22c7c 69 69 <!ENTITY readline-fixes-patch-size "24 KB"> 70 70 71 <!ENTITY vim-branch_update-patch "vim-&vim-version;-branch_update- 2.patch">72 <!ENTITY vim-branch_update-patch-md5 " 907803cbb34d217b9522aaf4c6024632">73 <!ENTITY vim-branch_update-patch-size "1 52KB">71 <!ENTITY vim-branch_update-patch "vim-&vim-version;-branch_update-3.patch"> 72 <!ENTITY vim-branch_update-patch-md5 "8a08f1a9562183a0214595c915565078"> 73 <!ENTITY vim-branch_update-patch-size "168 KB"> 74 74 75 75 <!ENTITY zlib-fpic-patch "zlib-&zlib-version;-fPIC-1.patch"> -
patches/vim-7.2-branch_update-3.patch
r06dcdf6 r1f22c7c 1 1 Submitted By: Jim Gifford (jim at linuxfromscratch dot org) 2 Date: 12- 20-20082 Date: 12-30-2008 3 3 Initial Package Version: 7.2 4 4 Origin: Upstream 5 5 Upstream Status: Applied 6 Description: Contains all upstream patches up to 7.2.0 696 Description: Contains all upstream patches up to 7.2.076 7 7 The following patches were skipped 8 007 036 041 049 8 007 036 041 049 071 072 074 9 9 10 10 diff -Naur vim72.orig/Filelist vim72/Filelist 11 11 --- vim72.orig/Filelist 2008-07-06 11:02:23.000000000 -0700 12 +++ vim72/Filelist 2008-12- 20 15:00:39.000000000 -080012 +++ vim72/Filelist 2008-12-30 16:15:18.000000000 -0800 13 13 @@ -285,6 +285,7 @@ 14 14 src/proto/os_win32.pro \ … … 21 21 diff -Naur vim72.orig/runtime/doc/cmdline.txt vim72/runtime/doc/cmdline.txt 22 22 --- vim72.orig/runtime/doc/cmdline.txt 2008-08-09 07:22:59.000000000 -0700 23 +++ vim72/runtime/doc/cmdline.txt 2008-12- 20 15:01:04.000000000 -080023 +++ vim72/runtime/doc/cmdline.txt 2008-12-30 16:15:47.000000000 -0800 24 24 @@ -1,4 +1,4 @@ 25 25 -*cmdline.txt* For Vim version 7.2. Last change: 2008 Jul 29 … … 80 80 diff -Naur vim72.orig/runtime/doc/eval.txt vim72/runtime/doc/eval.txt 81 81 --- vim72.orig/runtime/doc/eval.txt 2008-08-09 07:22:59.000000000 -0700 82 +++ vim72/runtime/doc/eval.txt 2008-12- 20 15:02:44.000000000 -080082 +++ vim72/runtime/doc/eval.txt 2008-12-30 16:17:36.000000000 -0800 83 83 @@ -1,4 +1,4 @@ 84 84 -*eval.txt* For Vim version 7.2. Last change: 2008 Aug 09 … … 200 200 diff -Naur vim72.orig/runtime/doc/options.txt vim72/runtime/doc/options.txt 201 201 --- vim72.orig/runtime/doc/options.txt 2008-08-09 07:22:59.000000000 -0700 202 +++ vim72/runtime/doc/options.txt 2008-12- 20 15:02:01.000000000 -0800202 +++ vim72/runtime/doc/options.txt 2008-12-30 16:16:50.000000000 -0800 203 203 @@ -1,4 +1,4 @@ 204 204 -*options.txt* For Vim version 7.2. Last change: 2008 Aug 06 … … 220 220 diff -Naur vim72.orig/runtime/doc/spell.txt vim72/runtime/doc/spell.txt 221 221 --- vim72.orig/runtime/doc/spell.txt 2008-08-09 07:23:00.000000000 -0700 222 +++ vim72/runtime/doc/spell.txt 2008-12- 20 15:02:27.000000000 -0800222 +++ vim72/runtime/doc/spell.txt 2008-12-30 16:17:18.000000000 -0800 223 223 @@ -1,4 +1,4 @@ 224 224 -*spell.txt* For Vim version 7.2. Last change: 2008 Jun 21 … … 350 350 diff -Naur vim72.orig/runtime/doc/starting.txt vim72/runtime/doc/starting.txt 351 351 --- vim72.orig/runtime/doc/starting.txt 2008-08-09 07:23:00.000000000 -0700 352 +++ vim72/runtime/doc/starting.txt 2008-12- 20 15:01:04.000000000 -0800352 +++ vim72/runtime/doc/starting.txt 2008-12-30 16:15:47.000000000 -0800 353 353 @@ -1,4 +1,4 @@ 354 354 -*starting.txt* For Vim version 7.2. Last change: 2008 Jun 21 … … 412 412 diff -Naur vim72.orig/runtime/doc/usr_21.txt vim72/runtime/doc/usr_21.txt 413 413 --- vim72.orig/runtime/doc/usr_21.txt 2008-08-09 07:23:01.000000000 -0700 414 +++ vim72/runtime/doc/usr_21.txt 2008-12- 20 15:01:04.000000000 -0800414 +++ vim72/runtime/doc/usr_21.txt 2008-12-30 16:15:47.000000000 -0800 415 415 @@ -1,4 +1,4 @@ 416 416 -*usr_21.txt* For Vim version 7.2. Last change: 2007 May 01 … … 479 479 diff -Naur vim72.orig/runtime/scripts.vim vim72/runtime/scripts.vim 480 480 --- vim72.orig/runtime/scripts.vim 2008-08-08 15:27:21.000000000 -0700 481 +++ vim72/runtime/scripts.vim 2008-12- 20 14:59:55.000000000 -0800481 +++ vim72/runtime/scripts.vim 2008-12-30 16:14:26.000000000 -0800 482 482 @@ -234,6 +234,10 @@ 483 483 elseif s:line1 =~ '\<DTD\s\+XHTML\s' … … 493 493 diff -Naur vim72.orig/src/auto/configure vim72/src/auto/configure 494 494 --- vim72.orig/src/auto/configure 2008-07-24 05:40:36.000000000 -0700 495 +++ vim72/src/auto/configure 2008-12- 20 15:01:40.000000000 -0800495 +++ vim72/src/auto/configure 2008-12-30 16:16:27.000000000 -0800 496 496 @@ -16819,21 +16819,29 @@ 497 497 LDFLAGS="$LDFLAGS -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc" … … 534 534 diff -Naur vim72.orig/src/buffer.c vim72/src/buffer.c 535 535 --- vim72.orig/src/buffer.c 2008-08-06 04:00:48.000000000 -0700 536 +++ vim72/src/buffer.c 2008-12- 20 15:02:33.000000000 -0800536 +++ vim72/src/buffer.c 2008-12-30 16:17:24.000000000 -0800 537 537 @@ -647,6 +647,9 @@ 538 538 vim_free(buf->b_start_fenc); … … 610 610 diff -Naur vim72.orig/src/configure.in vim72/src/configure.in 611 611 --- vim72.orig/src/configure.in 2008-07-24 05:40:26.000000000 -0700 612 +++ vim72/src/configure.in 2008-12- 20 15:01:40.000000000 -0800612 +++ vim72/src/configure.in 2008-12-30 16:16:27.000000000 -0800 613 613 @@ -3152,18 +3152,25 @@ 614 614 dnl But only when making dependencies, cproto and lint don't take "-isystem". … … 645 645 diff -Naur vim72.orig/src/diff.c vim72/src/diff.c 646 646 --- vim72.orig/src/diff.c 2008-03-05 03:16:56.000000000 -0800 647 +++ vim72/src/diff.c 2008-12- 20 15:02:24.000000000 -0800647 +++ vim72/src/diff.c 2008-12-30 16:17:15.000000000 -0800 648 648 @@ -73,6 +73,8 @@ 649 649 { … … 735 735 diff -Naur vim72.orig/src/eval.c vim72/src/eval.c 736 736 --- vim72.orig/src/eval.c 2008-08-07 12:37:22.000000000 -0700 737 +++ vim72/src/eval.c 2008-12-20 15:02:44.000000000 -0800 738 @@ -348,6 +348,7 @@ 737 +++ vim72/src/eval.c 2008-12-30 16:17:49.000000000 -0800 738 @@ -32,6 +32,9 @@ 739 740 #define DICT_MAXNEST 100 /* maximum nesting of lists and dicts */ 741 742 +#define DO_NOT_FREE_CNT 99999 /* refcount for dict or list that should not 743 + be freed. */ 744 + 745 /* 746 * In a hashtab item "hi_key" points to "di_key" in a dictitem. 747 * This avoids adding a pointer to the hashtab item. 748 @@ -348,6 +351,7 @@ 739 749 {VV_NAME("mouse_col", VAR_NUMBER), 0}, 740 750 {VV_NAME("operator", VAR_STRING), VV_RO}, … … 744 754 745 755 /* shorthand */ 746 @@ -355,6 +35 6,7 @@756 @@ -355,6 +359,7 @@ 747 757 #define vv_nr vv_di.di_tv.vval.v_number 748 758 #define vv_float vv_di.di_tv.vval.v_float … … 752 762 753 763 /* 754 @@ -426,7 +4 28,6 @@764 @@ -426,7 +431,6 @@ 755 765 static long list_idx_of_item __ARGS((list_T *l, listitem_T *item)); 756 766 static void list_append __ARGS((list_T *l, listitem_T *item)); … … 760 770 static int list_insert_tv __ARGS((list_T *l, typval_T *tv, listitem_T *item)); 761 771 static int list_extend __ARGS((list_T *l1, list_T *l2, listitem_T *bef)); 762 @@ -845,11 +846,17 @@ 772 @@ -788,6 +792,8 @@ 773 static void func_unref __ARGS((char_u *name)); 774 static void func_ref __ARGS((char_u *name)); 775 static void call_user_func __ARGS((ufunc_T *fp, int argcount, typval_T *argvars, typval_T *rettv, linenr_T firstline, linenr_T lastline, dict_T *selfdict)); 776 +static int can_free_funccal __ARGS((funccall_T *fc, int copyID)) ; 777 +static void free_funccal __ARGS((funccall_T *fc, int free_val)); 778 static void add_nr_var __ARGS((dict_T *dp, dictitem_T *v, char *name, varnumber_T nr)); 779 static win_T *find_win_by_nr __ARGS((typval_T *vp, tabpage_T *tp)); 780 static void getwinvar __ARGS((typval_T *argvars, typval_T *rettv, int off)); 781 @@ -845,11 +851,17 @@ 763 782 p = &vimvars[i]; 764 783 if (p->vv_di.di_tv.v_type == VAR_STRING) … … 780 799 781 800 /* script-local variables */ 782 @@ -1256,23 +1263,26 @@ 801 @@ -916,6 +928,10 @@ 802 /* pointer to funccal for currently active function */ 803 funccall_T *current_funccal = NULL; 804 805 +/* pointer to list of previously used funccal, still around because some 806 + * item in it is still being used. */ 807 +funccall_T *previous_funccal = NULL; 808 + 809 /* 810 * Return TRUE when a function was ended by a ":return" command. 811 */ 812 @@ -1256,23 +1272,26 @@ 783 813 784 814 /* … … 810 840 ga_init2(&ga, (int)sizeof(char), 80); 811 841 if (tv.vval.v_list != NULL) 812 @@ -1280,6 +129 0,13 @@842 @@ -1280,6 +1299,13 @@ 813 843 ga_append(&ga, NUL); 814 844 retval = (char_u *)ga.ga_data; … … 824 854 retval = vim_strsave(get_tv_string(&tv)); 825 855 clear_tv(&tv); 826 @@ -3277,7 +3 294,7 @@856 @@ -3277,7 +3303,7 @@ 827 857 828 858 if (*startarg != '(') … … 833 863 } 834 864 835 @@ -3657,8 +36 74,8 @@865 @@ -3657,8 +3683,8 @@ 836 866 } 837 867 … … 844 874 static int 845 875 tv_islocked(tv) 846 @@ -6047,6 +60 64,25 @@876 @@ -6047,6 +6073,25 @@ 847 877 } 848 878 … … 870 900 * Returns -1 when "item" is not in the list. 871 901 */ 872 @@ -6137,7 +61 73,7 @@902 @@ -6137,7 +6182,7 @@ 873 903 * When "len" >= 0 use "str[len]". 874 904 * Returns FAIL when out of memory. … … 879 909 list_T *l; 880 910 char_u *str; 881 @@ -6497,6 +6533,9 @@ 911 @@ -6454,7 +6499,7 @@ 912 buf_T *buf; 913 win_T *wp; 914 int i; 915 - funccall_T *fc; 916 + funccall_T *fc, **pfc; 917 int did_free = FALSE; 918 #ifdef FEAT_WINDOWS 919 tabpage_T *tp; 920 @@ -6497,6 +6542,9 @@ 882 921 set_ref_in_ht(&fc->l_avars.dv_hashtab, copyID); 883 922 } … … 889 928 * 2. Go through the list of dicts and free items without the copyID. 890 929 */ 891 @@ -6587,7 +6626,7 @@ 930 @@ -6535,6 +6583,20 @@ 931 else 932 ll = ll->lv_used_next; 933 934 + /* check if any funccal can be freed now */ 935 + for (pfc = &previous_funccal; *pfc != NULL; ) 936 + { 937 + if (can_free_funccal(*pfc, copyID)) 938 + { 939 + fc = *pfc; 940 + *pfc = fc->caller; 941 + free_funccal(fc, TRUE); 942 + did_free = TRUE; 943 + } 944 + else 945 + pfc = &(*pfc)->caller; 946 + } 947 + 948 return did_free; 949 } 950 951 @@ -6587,7 +6649,7 @@ 892 952 { 893 953 case VAR_DICT: … … 898 958 /* Didn't see this dict yet. */ 899 959 dd->dv_copyID = copyID; 900 @@ -6597,7 +66 36,7 @@960 @@ -6597,7 +6659,7 @@ 901 961 902 962 case VAR_LIST: … … 907 967 /* Didn't see this list yet. */ 908 968 ll->lv_copyID = copyID; 909 @@ -7525,8 +75 64,8 @@969 @@ -7525,8 +7587,8 @@ 910 970 {"getwinposx", 0, 0, f_getwinposx}, 911 971 {"getwinposy", 0, 0, f_getwinposy}, … … 918 978 {"has_key", 2, 2, f_has_key}, 919 979 {"haslocaldir", 0, 0, f_haslocaldir}, 920 @@ -9518,7 +95 57,7 @@980 @@ -9518,7 +9580,7 @@ 921 981 else 922 982 { … … 927 987 && get_tv_number_chk(&argvars[1], &error)) 928 988 flags |= WILD_KEEP_ALL; 929 @@ -10300,7 +103 39,8 @@989 @@ -10300,7 +10362,8 @@ 930 990 s = get_tv_string(&argvars[0]); 931 991 if (s == NULL || *s == NUL || VIM_ISDIGIT(*s)) … … 937 997 else 938 998 { 939 @@ -10602,7 +106 42,7 @@999 @@ -10602,7 +10665,7 @@ 940 1000 # ifdef FEAT_WINDOWS 941 1001 win_T *wp; … … 946 1006 if (row >= 0 && col >= 0) 947 1007 { 948 @@ -10612,9 +106 52,9 @@1008 @@ -10612,9 +10675,9 @@ 949 1009 (void)mouse_comp_pos(win, &row, &col, &lnum); 950 1010 # ifdef FEAT_WINDOWS … … 958 1018 vimvars[VV_MOUSE_COL].vv_nr = col + 1; 959 1019 } 960 @@ -11284,13 +113 24,25 @@1020 @@ -11284,13 +11347,25 @@ 961 1021 typval_T *argvars; 962 1022 typval_T *rettv; … … 988 1048 989 1049 /* 990 @@ -11301,14 +113 53,22 @@1050 @@ -11301,14 +11376,22 @@ 991 1051 typval_T *argvars; 992 1052 typval_T *rettv; … … 1013 1073 1014 1074 /* 1015 @@ -11782,6 +118 42,10 @@1075 @@ -11782,6 +11865,10 @@ 1016 1076 n = has_patch(atoi((char *)name + 5)); 1017 1077 else if (STRICMP(name, "vim_starting") == 0) … … 1024 1084 else if (STRICMP(name, "balloon_multiline") == 0) 1025 1085 n = multiline_balloon_available(); 1026 @@ -15838,10 +159 02,9 @@1086 @@ -15838,10 +15925,9 @@ 1027 1087 if (res == FAIL) 1028 1088 res = ITEM_COMPARE_FAIL; … … 1036 1096 return res; 1037 1097 } 1038 @@ -16590,8 +166 53,11 @@1098 @@ -16590,8 +16676,11 @@ 1039 1099 p = highlight_has_attr(id, HL_INVERSE, modec); 1040 1100 break; … … 1050 1110 1051 1111 case 'u': 1052 @@ -16658,7 +167 24,7 @@1112 @@ -16658,7 +16747,7 @@ 1053 1113 col = get_tv_number(&argvars[1]) - 1; /* -1 on type error */ 1054 1114 … … 1059 1119 { 1060 1120 (void)syn_get_id(curwin, lnum, (colnr_T)col, FALSE, NULL, TRUE); 1061 @@ -18097,14 +181 63,28 @@1121 @@ -18097,14 +18186,28 @@ 1062 1122 } 1063 1123 … … 1091 1151 vimvars[VV_COUNT1].vv_nr = count1; 1092 1152 } 1093 @@ -18132,6 +182 12,20 @@1153 @@ -18132,6 +18235,20 @@ 1094 1154 } 1095 1155 … … 1112 1172 */ 1113 1173 void 1114 @@ -20590,6 +20684,9 @@ 1174 @@ -18868,7 +18985,7 @@ 1175 dictitem_T *dict_var; 1176 { 1177 hash_init(&dict->dv_hashtab); 1178 - dict->dv_refcount = 99999; 1179 + dict->dv_refcount = DO_NOT_FREE_CNT; 1180 dict_var->di_tv.vval.v_dict = dict; 1181 dict_var->di_tv.v_type = VAR_DICT; 1182 dict_var->di_tv.v_lock = VAR_FIXED; 1183 @@ -19205,6 +19322,8 @@ 1184 * Copy the values from typval_T "from" to typval_T "to". 1185 * When needed allocates string or increases reference count. 1186 * Does not make a copy of a list or dict but copies the reference! 1187 + * It is OK for "from" and "to" to point to the same item. This is used to 1188 + * make a copy later. 1189 */ 1190 static void 1191 copy_tv(from, to) 1192 @@ -20590,6 +20709,9 @@ 1115 1193 int st_len = 0; 1116 1194 … … 1122 1200 1123 1201 for (hi = func_hashtab.ht_array; todo > 0; ++hi) 1124 @@ -20638,6 +207 35,8 @@1202 @@ -20638,6 +20760,8 @@ 1125 1203 prof_self_cmp); 1126 1204 prof_sort_list(fd, sorttab, st_len, "SELF", TRUE); … … 1131 1209 1132 1210 static void 1133 @@ -21082,8 +21181,11 @@ 1134 init_var_dict(&fc.l_avars, &fc.l_avars_var); 1135 add_nr_var(&fc.l_avars, &fc.fixvar[fixvar_idx++].var, "0", 1211 @@ -21012,7 +21136,7 @@ 1212 char_u *save_sourcing_name; 1213 linenr_T save_sourcing_lnum; 1214 scid_T save_current_SID; 1215 - funccall_T fc; 1216 + funccall_T *fc; 1217 int save_did_emsg; 1218 static int depth = 0; 1219 dictitem_T *v; 1220 @@ -21038,36 +21162,37 @@ 1221 1222 line_breakcheck(); /* check for CTRL-C hit */ 1223 1224 - fc.caller = current_funccal; 1225 - current_funccal = &fc; 1226 - fc.func = fp; 1227 - fc.rettv = rettv; 1228 + fc = (funccall_T *)alloc(sizeof(funccall_T)); 1229 + fc->caller = current_funccal; 1230 + current_funccal = fc; 1231 + fc->func = fp; 1232 + fc->rettv = rettv; 1233 rettv->vval.v_number = 0; 1234 - fc.linenr = 0; 1235 - fc.returned = FALSE; 1236 - fc.level = ex_nesting_level; 1237 + fc->linenr = 0; 1238 + fc->returned = FALSE; 1239 + fc->level = ex_nesting_level; 1240 /* Check if this function has a breakpoint. */ 1241 - fc.breakpoint = dbg_find_breakpoint(FALSE, fp->uf_name, (linenr_T)0); 1242 - fc.dbg_tick = debug_tick; 1243 + fc->breakpoint = dbg_find_breakpoint(FALSE, fp->uf_name, (linenr_T)0); 1244 + fc->dbg_tick = debug_tick; 1245 1246 /* 1247 - * Note about using fc.fixvar[]: This is an array of FIXVAR_CNT variables 1248 + * Note about using fc->fixvar[]: This is an array of FIXVAR_CNT variables 1249 * with names up to VAR_SHORT_LEN long. This avoids having to alloc/free 1250 * each argument variable and saves a lot of time. 1251 */ 1252 /* 1253 * Init l: variables. 1254 */ 1255 - init_var_dict(&fc.l_vars, &fc.l_vars_var); 1256 + init_var_dict(&fc->l_vars, &fc->l_vars_var); 1257 if (selfdict != NULL) 1258 { 1259 /* Set l:self to "selfdict". Use "name" to avoid a warning from 1260 * some compiler that checks the destination size. */ 1261 - v = &fc.fixvar[fixvar_idx++].var; 1262 + v = &fc->fixvar[fixvar_idx++].var; 1263 name = v->di_key; 1264 STRCPY(name, "self"); 1265 v->di_flags = DI_FLAGS_RO + DI_FLAGS_FIX; 1266 - hash_add(&fc.l_vars.dv_hashtab, DI2HIKEY(v)); 1267 + hash_add(&fc->l_vars.dv_hashtab, DI2HIKEY(v)); 1268 v->di_tv.v_type = VAR_DICT; 1269 v->di_tv.v_lock = 0; 1270 v->di_tv.vval.v_dict = selfdict; 1271 @@ -21079,28 +21204,31 @@ 1272 * Set a:0 to "argcount". 1273 * Set a:000 to a list with room for the "..." arguments. 1274 */ 1275 - init_var_dict(&fc.l_avars, &fc.l_avars_var); 1276 - add_nr_var(&fc.l_avars, &fc.fixvar[fixvar_idx++].var, "0", 1277 + init_var_dict(&fc->l_avars, &fc->l_avars_var); 1278 + add_nr_var(&fc->l_avars, &fc->fixvar[fixvar_idx++].var, "0", 1136 1279 (varnumber_T)(argcount - fp->uf_args.ga_len)); 1280 - v = &fc.fixvar[fixvar_idx++].var; 1281 - STRCPY(v->di_key, "000"); 1137 1282 + /* Use "name" to avoid a warning from some compiler that checks the 1138 1283 + * destination size. */ 1139 v = &fc.fixvar[fixvar_idx++].var; 1140 - STRCPY(v->di_key, "000"); 1284 + v = &fc->fixvar[fixvar_idx++].var; 1141 1285 + name = v->di_key; 1142 1286 + STRCPY(name, "000"); 1143 1287 v->di_flags = DI_FLAGS_RO | DI_FLAGS_FIX; 1144 hash_add(&fc.l_avars.dv_hashtab, DI2HIKEY(v)); 1288 - hash_add(&fc.l_avars.dv_hashtab, DI2HIKEY(v)); 1289 + hash_add(&fc->l_avars.dv_hashtab, DI2HIKEY(v)); 1145 1290 v->di_tv.v_type = VAR_LIST; 1146 @@ -21204,7 +21306,7 @@ 1291 v->di_tv.v_lock = VAR_FIXED; 1292 - v->di_tv.vval.v_list = &fc.l_varlist; 1293 - vim_memset(&fc.l_varlist, 0, sizeof(list_T)); 1294 - fc.l_varlist.lv_refcount = 99999; 1295 - fc.l_varlist.lv_lock = VAR_FIXED; 1296 + v->di_tv.vval.v_list = &fc->l_varlist; 1297 + vim_memset(&fc->l_varlist, 0, sizeof(list_T)); 1298 + fc->l_varlist.lv_refcount = DO_NOT_FREE_CNT; 1299 + fc->l_varlist.lv_lock = VAR_FIXED; 1300 1301 /* 1302 * Set a:firstline to "firstline" and a:lastline to "lastline". 1303 * Set a:name to named arguments. 1304 * Set a:N to the "..." arguments. 1305 */ 1306 - add_nr_var(&fc.l_avars, &fc.fixvar[fixvar_idx++].var, "firstline", 1307 + add_nr_var(&fc->l_avars, &fc->fixvar[fixvar_idx++].var, "firstline", 1308 (varnumber_T)firstline); 1309 - add_nr_var(&fc.l_avars, &fc.fixvar[fixvar_idx++].var, "lastline", 1310 + add_nr_var(&fc->l_avars, &fc->fixvar[fixvar_idx++].var, "lastline", 1311 (varnumber_T)lastline); 1312 for (i = 0; i < argcount; ++i) 1313 { 1314 @@ -21116,7 +21244,7 @@ 1315 } 1316 if (fixvar_idx < FIXVAR_CNT && STRLEN(name) <= VAR_SHORT_LEN) 1317 { 1318 - v = &fc.fixvar[fixvar_idx++].var; 1319 + v = &fc->fixvar[fixvar_idx++].var; 1320 v->di_flags = DI_FLAGS_RO | DI_FLAGS_FIX; 1321 } 1322 else 1323 @@ -21128,7 +21256,7 @@ 1324 v->di_flags = DI_FLAGS_RO; 1325 } 1326 STRCPY(v->di_key, name); 1327 - hash_add(&fc.l_avars.dv_hashtab, DI2HIKEY(v)); 1328 + hash_add(&fc->l_avars.dv_hashtab, DI2HIKEY(v)); 1329 1330 /* Note: the values are copied directly to avoid alloc/free. 1331 * "argvars" must have VAR_FIXED for v_lock. */ 1332 @@ -21137,9 +21265,9 @@ 1333 1334 if (ai >= 0 && ai < MAX_FUNC_ARGS) 1335 { 1336 - list_append(&fc.l_varlist, &fc.l_listitems[ai]); 1337 - fc.l_listitems[ai].li_tv = argvars[i]; 1338 - fc.l_listitems[ai].li_tv.v_lock = VAR_FIXED; 1339 + list_append(&fc->l_varlist, &fc->l_listitems[ai]); 1340 + fc->l_listitems[ai].li_tv = argvars[i]; 1341 + fc->l_listitems[ai].li_tv.v_lock = VAR_FIXED; 1342 } 1343 } 1344 1345 @@ -21204,7 +21332,7 @@ 1147 1346 if (!fp->uf_profiling && has_profiling(FALSE, fp->uf_name, NULL)) 1148 1347 func_do_profile(fp); 1149 1348 if (fp->uf_profiling 1150 1349 - || (fc.caller != NULL && &fc.caller->func->uf_profiling)) 1151 + || (fc.caller != NULL && fc.caller->func->uf_profiling))1350 + || (fc->caller != NULL && fc->caller->func->uf_profiling)) 1152 1351 { 1153 1352 ++fp->uf_tm_count; 1154 1353 profile_start(&call_start); 1155 @@ -21235,13 +21337,13 @@ 1354 @@ -21220,7 +21348,7 @@ 1355 did_emsg = FALSE; 1356 1357 /* call do_cmdline() to execute the lines */ 1358 - do_cmdline(NULL, get_func_line, (void *)&fc, 1359 + do_cmdline(NULL, get_func_line, (void *)fc, 1360 DOCMD_NOWAIT|DOCMD_VERBOSE|DOCMD_REPEAT); 1361 1362 --RedrawingDisabled; 1363 @@ -21235,16 +21363,16 @@ 1156 1364 1157 1365 #ifdef FEAT_PROFILE 1158 1366 if (do_profiling == PROF_YES && (fp->uf_profiling 1159 1367 - || (fc.caller != NULL && &fc.caller->func->uf_profiling))) 1160 + || (fc .caller != NULL && fc.caller->func->uf_profiling)))1368 + || (fc->caller != NULL && fc->caller->func->uf_profiling))) 1161 1369 { 1162 1370 profile_end(&call_start); … … 1165 1373 profile_self(&fp->uf_tm_self, &call_start, &fp->uf_tm_children); 1166 1374 - if (fc.caller != NULL && &fc.caller->func->uf_profiling) 1167 + if (fc .caller != NULL && fc.caller->func->uf_profiling)1375 + if (fc->caller != NULL && fc->caller->func->uf_profiling) 1168 1376 { 1169 profile_add(&fc.caller->func->uf_tm_children, &call_start); 1170 profile_add(&fc.caller->func->uf_tml_children, &call_start); 1171 @@ -21886,6 +21988,62 @@ 1377 - profile_add(&fc.caller->func->uf_tm_children, &call_start); 1378 - profile_add(&fc.caller->func->uf_tml_children, &call_start); 1379 + profile_add(&fc->caller->func->uf_tm_children, &call_start); 1380 + profile_add(&fc->caller->func->uf_tml_children, &call_start); 1381 } 1382 } 1383 #endif 1384 @@ -21257,9 +21385,9 @@ 1385 1386 if (aborting()) 1387 smsg((char_u *)_("%s aborted"), sourcing_name); 1388 - else if (fc.rettv->v_type == VAR_NUMBER) 1389 + else if (fc->rettv->v_type == VAR_NUMBER) 1390 smsg((char_u *)_("%s returning #%ld"), sourcing_name, 1391 - (long)fc.rettv->vval.v_number); 1392 + (long)fc->rettv->vval.v_number); 1393 else 1394 { 1395 char_u buf[MSG_BUF_LEN]; 1396 @@ -21270,7 +21398,7 @@ 1397 /* The value may be very long. Skip the middle part, so that we 1398 * have some idea how it starts and ends. smsg() would always 1399 * truncate it at the end. */ 1400 - s = tv2string(fc.rettv, &tofree, numbuf2, 0); 1401 + s = tv2string(fc->rettv, &tofree, numbuf2, 0); 1402 if (s != NULL) 1403 { 1404 trunc_string(s, buf, MSG_BUF_CLEN); 1405 @@ -21306,14 +21434,84 @@ 1406 } 1407 1408 did_emsg |= save_did_emsg; 1409 - current_funccal = fc.caller; 1410 + current_funccal = fc->caller; 1411 + --depth; 1412 1413 - /* The a: variables typevals were not allocated, only free the allocated 1414 - * variables. */ 1415 - vars_clear_ext(&fc.l_avars.dv_hashtab, FALSE); 1416 + /* if the a:000 list and the a: dict are not referenced we can free the 1417 + * funccall_T and what's in it. */ 1418 + if (fc->l_varlist.lv_refcount == DO_NOT_FREE_CNT 1419 + && fc->l_vars.dv_refcount == DO_NOT_FREE_CNT 1420 + && fc->l_avars.dv_refcount == DO_NOT_FREE_CNT) 1421 + { 1422 + free_funccal(fc, FALSE); 1423 + } 1424 + else 1425 + { 1426 + hashitem_T *hi; 1427 + listitem_T *li; 1428 + int todo; 1429 1430 - vars_clear(&fc.l_vars.dv_hashtab); /* free all l: variables */ 1431 - --depth; 1432 + /* "fc" is still in use. This can happen when returning "a:000" or 1433 + * assigning "l:" to a global variable. 1434 + * Link "fc" in the list for garbage collection later. */ 1435 + fc->caller = previous_funccal; 1436 + previous_funccal = fc; 1437 + 1438 + /* Make a copy of the a: variables, since we didn't do that above. */ 1439 + todo = (int)fc->l_avars.dv_hashtab.ht_used; 1440 + for (hi = fc->l_avars.dv_hashtab.ht_array; todo > 0; ++hi) 1441 + { 1442 + if (!HASHITEM_EMPTY(hi)) 1443 + { 1444 + --todo; 1445 + v = HI2DI(hi); 1446 + copy_tv(&v->di_tv, &v->di_tv); 1447 + } 1448 + } 1449 + 1450 + /* Make a copy of the a:000 items, since we didn't do that above. */ 1451 + for (li = fc->l_varlist.lv_first; li != NULL; li = li->li_next) 1452 + copy_tv(&li->li_tv, &li->li_tv); 1453 + } 1454 +} 1455 + 1456 +/* 1457 + * Return TRUE if items in "fc" do not have "copyID". That means they are not 1458 + * referenced from anywyere. 1459 + */ 1460 + static int 1461 +can_free_funccal(fc, copyID) 1462 + funccall_T *fc; 1463 + int copyID; 1464 +{ 1465 + return (fc->l_varlist.lv_copyID != copyID 1466 + && fc->l_vars.dv_copyID != copyID 1467 + && fc->l_avars.dv_copyID != copyID); 1468 +} 1469 + 1470 +/* 1471 + * Free "fc" and what it contains. 1472 + */ 1473 + static void 1474 +free_funccal(fc, free_val) 1475 + funccall_T *fc; 1476 + int free_val; /* a: vars were allocated */ 1477 +{ 1478 + listitem_T *li; 1479 + 1480 + /* The a: variables typevals may not have been allocated, only free the 1481 + * allocated variables. */ 1482 + vars_clear_ext(&fc->l_avars.dv_hashtab, free_val); 1483 + 1484 + /* free all l: variables */ 1485 + vars_clear(&fc->l_vars.dv_hashtab); 1486 + 1487 + /* Free the a:000 variables if they were allocated. */ 1488 + if (free_val) 1489 + for (li = fc->l_varlist.lv_first; li != NULL; li = li->li_next) 1490 + clear_tv(&li->li_tv); 1491 + 1492 + vim_free(fc); 1493 } 1494 1495 /* 1496 @@ -21886,6 +22084,62 @@ 1172 1497 } 1173 1498 } … … 1234 1559 diff -Naur vim72.orig/src/ex_cmds.c vim72/src/ex_cmds.c 1235 1560 --- vim72.orig/src/ex_cmds.c 2008-08-04 12:15:00.000000000 -0700 1236 +++ vim72/src/ex_cmds.c 2008-12- 20 15:02:13.000000000 -08001561 +++ vim72/src/ex_cmds.c 2008-12-30 16:17:03.000000000 -0800 1237 1562 @@ -24,7 +24,7 @@ 1238 1563 static void do_filter __ARGS((linenr_T line1, linenr_T line2, exarg_T *eap, char_u *cmd, int do_in, int do_out)); … … 1363 1688 diff -Naur vim72.orig/src/ex_cmds.h vim72/src/ex_cmds.h 1364 1689 --- vim72.orig/src/ex_cmds.h 2008-06-21 11:47:57.000000000 -0700 1365 +++ vim72/src/ex_cmds.h 2008-12- 20 15:01:04.000000000 -08001690 +++ vim72/src/ex_cmds.h 2008-12-30 16:15:47.000000000 -0800 1366 1691 @@ -278,7 +278,7 @@ 1367 1692 EX(CMD_crewind, "crewind", ex_cc, … … 1411 1736 diff -Naur vim72.orig/src/ex_cmds2.c vim72/src/ex_cmds2.c 1412 1737 --- vim72.orig/src/ex_cmds2.c 2008-07-13 09:18:22.000000000 -0700 1413 +++ vim72/src/ex_cmds2.c 2008-12- 20 15:00:13.000000000 -08001738 +++ vim72/src/ex_cmds2.c 2008-12-30 16:14:45.000000000 -0800 1414 1739 @@ -3145,8 +3145,8 @@ 1415 1740 verbose_leave(); … … 1425 1750 diff -Naur vim72.orig/src/ex_docmd.c vim72/src/ex_docmd.c 1426 1751 --- vim72.orig/src/ex_docmd.c 2008-07-26 04:51:05.000000000 -0700 1427 +++ vim72/src/ex_docmd.c 2008-12- 20 15:02:47.000000000 -08001752 +++ vim72/src/ex_docmd.c 2008-12-30 16:17:40.000000000 -0800 1428 1753 @@ -364,6 +364,7 @@ 1429 1754 # define ex_function ex_ni … … 1568 1893 diff -Naur vim72.orig/src/ex_getln.c vim72/src/ex_getln.c 1569 1894 --- vim72.orig/src/ex_getln.c 2008-08-08 02:31:33.000000000 -0700 1570 +++ vim72/src/ex_getln.c 2008-12- 20 15:02:01.000000000 -08001895 +++ vim72/src/ex_getln.c 2008-12-30 16:16:50.000000000 -0800 1571 1896 @@ -31,6 +31,8 @@ 1572 1897 int cmdattr; /* attributes for prompt */ … … 1702 2027 diff -Naur vim72.orig/src/feature.h vim72/src/feature.h 1703 2028 --- vim72.orig/src/feature.h 2008-08-06 04:00:39.000000000 -0700 1704 +++ vim72/src/feature.h 2008-12- 20 15:01:04.000000000 -08002029 +++ vim72/src/feature.h 2008-12-30 16:15:47.000000000 -0800 1705 2030 @@ -767,9 +767,13 @@ 1706 2031 … … 1721 2046 diff -Naur vim72.orig/src/fileio.c vim72/src/fileio.c 1722 2047 --- vim72.orig/src/fileio.c 2008-08-06 04:01:03.000000000 -0700 1723 +++ vim72/src/fileio.c 2008-12- 20 15:02:13.000000000 -08002048 +++ vim72/src/fileio.c 2008-12-30 16:18:07.000000000 -0800 1724 2049 @@ -932,7 +932,10 @@ 1725 2050 else … … 1806 2131 } while (tbuf[FGETS_SIZE - 2] != NUL && tbuf[FGETS_SIZE - 2] != '\n'); 1807 2132 } 1808 @@ -8523,6 +8522,7 @@ 2133 @@ -6120,6 +6119,47 @@ 2134 if (mch_stat((char *)from, &st) < 0) 2135 return -1; 2136 2137 +#ifdef UNIX 2138 + { 2139 + struct stat st_to; 2140 + char tempname[MAXPATHL + 1]; 2141 + 2142 + /* It's possible for the source and destination to be the same file. 2143 + * This happens when "from" and "to" differ in case and are on a FAT32 2144 + * filesystem. In that case go through a temp file name. */ 2145 + if (mch_stat((char *)to, &st_to) >= 0 2146 + && st.st_dev == st_to.st_dev 2147 + && st.st_ino == st_to.st_ino) 2148 + { 2149 + /* Find a name that doesn't exist and is in the same directory. 2150 + * Move "from" to "tempname" and then to "to". */ 2151 + if (STRLEN(from) >= MAXPATHL - 5) 2152 + return -1; 2153 + STRCPY(tempname, from); 2154 + for (n = 123; n < 99999; ++n) 2155 + { 2156 + sprintf(gettail(tempname), "%d", n); 2157 + if (mch_stat(tempname, &st_to) < 0) 2158 + { 2159 + if (mch_rename((char *)from, tempname) == 0) 2160 + { 2161 + if (mch_rename(tempname, (char *)to) == 0) 2162 + return 0; 2163 + /* Strange, the second step failed. Try moving the 2164 + * file back and return failure. */ 2165 + mch_rename(tempname, (char *)from); 2166 + return -1; 2167 + } 2168 + /* If it fails for one temp name it will most likely fail 2169 + * for any temp name, give up. */ 2170 + return -1; 2171 + } 2172 + } 2173 + return -1; 2174 + } 2175 + } 2176 +#endif 2177 + 2178 /* 2179 * Delete the "to" file, this is required on some systems to make the 2180 * mch_rename() work, on other systems it makes sure that we don't have 2181 @@ -8523,6 +8563,7 @@ 1809 2182 char_u *save_sourcing_name; 1810 2183 linenr_T save_sourcing_lnum; … … 1814 2187 char_u *save_autocmd_match; 1815 2188 int save_autocmd_busy; 1816 @@ -8601,6 +86 01,7 @@2189 @@ -8601,6 +8642,7 @@ 1817 2190 * Save the autocmd_* variables and info about the current buffer. 1818 2191 */ … … 1822 2195 save_autocmd_match = autocmd_match; 1823 2196 save_autocmd_busy = autocmd_busy; 1824 @@ -8618,14 +86 19,15 @@2197 @@ -8618,14 +8660,15 @@ 1825 2198 if (fname != NULL && *fname != NUL) 1826 2199 autocmd_fname = fname; … … 1840 2213 /* 1841 2214 * Set the buffer number to be used for <abuf>. 1842 @@ -8810,6 +88 12,7 @@2215 @@ -8810,6 +8853,7 @@ 1843 2216 sourcing_lnum = save_sourcing_lnum; 1844 2217 vim_free(autocmd_fname); … … 1848 2221 autocmd_match = save_autocmd_match; 1849 2222 #ifdef FEAT_EVAL 1850 @@ -8918,7 +89 21,7 @@2223 @@ -8918,7 +8962,7 @@ 1851 2224 { 1852 2225 apc->curpat = NULL; … … 1857 2230 * buffer number. */ 1858 2231 if (ap->pat != NULL && ap->cmds != NULL 1859 @@ -9104,7 +91 07,7 @@2232 @@ -9104,7 +9148,7 @@ 1860 2233 set_context_in_autocmd(xp, arg, doautocmd) 1861 2234 expand_T *xp; … … 1868 2241 diff -Naur vim72.orig/src/fold.c vim72/src/fold.c 1869 2242 --- vim72.orig/src/fold.c 2008-08-06 04:01:12.000000000 -0700 1870 +++ vim72/src/fold.c 2008-12- 20 15:02:13.000000000 -08002243 +++ vim72/src/fold.c 2008-12-30 16:17:03.000000000 -0800 1871 2244 @@ -48,7 +48,7 @@ 1872 2245 static int foldFind __ARGS((garray_T *gap, linenr_T lnum, fold_T **fpp)); … … 1902 2275 diff -Naur vim72.orig/src/getchar.c vim72/src/getchar.c 1903 2276 --- vim72.orig/src/getchar.c 2008-07-22 09:57:48.000000000 -0700 1904 +++ vim72/src/getchar.c 2008-12- 20 15:02:09.000000000 -08002277 +++ vim72/src/getchar.c 2008-12-30 16:16:59.000000000 -0800 1905 2278 @@ -4702,7 +4702,7 @@ 1906 2279 return FAIL; … … 1923 2296 diff -Naur vim72.orig/src/globals.h vim72/src/globals.h 1924 2297 --- vim72.orig/src/globals.h 2008-07-26 04:53:29.000000000 -0700 1925 +++ vim72/src/globals.h 2008-12- 20 15:02:13.000000000 -08002298 +++ vim72/src/globals.h 2008-12-30 16:17:03.000000000 -0800 1926 2299 @@ -1022,6 +1022,7 @@ 1927 2300 #endif … … 1949 2322 diff -Naur vim72.orig/src/gui.c vim72/src/gui.c 1950 2323 --- vim72.orig/src/gui.c 2008-07-27 12:32:14.000000000 -0700 1951 +++ vim72/src/gui.c 2008-12- 20 15:02:41.000000000 -08002324 +++ vim72/src/gui.c 2008-12-30 16:17:34.000000000 -0800 1952 2325 @@ -139,7 +139,7 @@ 1953 2326 /* The read returns when the child closes the pipe (or when … … 2042 2415 diff -Naur vim72.orig/src/gui_at_sb.c vim72/src/gui_at_sb.c 2043 2416 --- vim72.orig/src/gui_at_sb.c 2004-06-07 07:32:25.000000000 -0700 2044 +++ vim72/src/gui_at_sb.c 2008-12- 20 15:02:13.000000000 -08002417 +++ vim72/src/gui_at_sb.c 2008-12-30 16:17:03.000000000 -0800 2045 2418 @@ -1078,6 +1078,12 @@ 2046 2419 Cardinal *num_params; /* unused */ … … 2068 2441 diff -Naur vim72.orig/src/gui_gtk_x11.c vim72/src/gui_gtk_x11.c 2069 2442 --- vim72.orig/src/gui_gtk_x11.c 2008-07-04 03:46:24.000000000 -0700 2070 +++ vim72/src/gui_gtk_x11.c 2008-12- 20 15:02:13.000000000 -08002443 +++ vim72/src/gui_gtk_x11.c 2008-12-30 16:17:03.000000000 -0800 2071 2444 @@ -4070,14 +4070,14 @@ 2072 2445 … … 2092 2465 diff -Naur vim72.orig/src/gui_x11.c vim72/src/gui_x11.c 2093 2466 --- vim72.orig/src/gui_x11.c 2008-06-08 08:13:45.000000000 -0700 2094 +++ vim72/src/gui_x11.c 2008-12- 20 15:01:15.000000000 -08002467 +++ vim72/src/gui_x11.c 2008-12-30 16:15:59.000000000 -0800 2095 2468 @@ -2450,7 +2450,7 @@ 2096 2469 *colorPtr = colortable[closest]; … … 2104 2477 diff -Naur vim72.orig/src/gui_xmdlg.c vim72/src/gui_xmdlg.c 2105 2478 --- vim72.orig/src/gui_xmdlg.c 2008-06-21 09:05:32.000000000 -0700 2106 +++ vim72/src/gui_xmdlg.c 2008-12- 20 15:02:13.000000000 -08002479 +++ vim72/src/gui_xmdlg.c 2008-12-30 16:17:03.000000000 -0800 2107 2480 @@ -369,10 +369,10 @@ 2108 2481 char buf[TEMP_BUF_SIZE]; … … 2260 2633 diff -Naur vim72.orig/src/gui_xmebw.c vim72/src/gui_xmebw.c 2261 2634 --- vim72.orig/src/gui_xmebw.c 2007-09-06 03:57:51.000000000 -0700 2262 +++ vim72/src/gui_xmebw.c 2008-12- 20 15:02:13.000000000 -08002635 +++ vim72/src/gui_xmebw.c 2008-12-30 16:17:03.000000000 -0800 2263 2636 @@ -1256,7 +1256,7 @@ 2264 2637 } … … 2287 2660 diff -Naur vim72.orig/src/if_cscope.c vim72/src/if_cscope.c 2288 2661 --- vim72.orig/src/if_cscope.c 2008-06-24 09:32:34.000000000 -0700 2289 +++ vim72/src/if_cscope.c 2008-12- 20 14:59:49.000000000 -08002662 +++ vim72/src/if_cscope.c 2008-12-30 16:14:15.000000000 -0800 2290 2663 @@ -74,7 +74,7 @@ 2291 2664 { "add", cs_add, … … 2317 2690 diff -Naur vim72.orig/src/if_cscope.h vim72/src/if_cscope.h 2318 2691 --- vim72.orig/src/if_cscope.h 2007-09-02 07:51:08.000000000 -0700 2319 +++ vim72/src/if_cscope.h 2008-12- 20 14:59:49.000000000 -08002692 +++ vim72/src/if_cscope.h 2008-12-30 16:14:15.000000000 -0800 2320 2693 @@ -42,17 +42,6 @@ 2321 2694 * f 7name Find this file … … 2338 2711 diff -Naur vim72.orig/src/if_perl.xs vim72/src/if_perl.xs 2339 2712 --- vim72.orig/src/if_perl.xs 2008-07-17 13:55:09.000000000 -0700 2340 +++ vim72/src/if_perl.xs 2008-12- 20 15:02:36.000000000 -08002713 +++ vim72/src/if_perl.xs 2008-12-30 16:17:28.000000000 -0800 2341 2714 @@ -136,6 +136,9 @@ 2342 2715 # define Perl_newXS_flags dll_Perl_newXS_flags … … 2389 2762 diff -Naur vim72.orig/src/if_python.c vim72/src/if_python.c 2390 2763 --- vim72.orig/src/if_python.c 2008-07-17 14:09:32.000000000 -0700 2391 +++ vim72/src/if_python.c 2008-12- 20 15:01:43.000000000 -08002764 +++ vim72/src/if_python.c 2008-12-30 16:16:31.000000000 -0800 2392 2765 @@ -531,6 +531,12 @@ 2393 2766 if (PythonMod_Init()) … … 2415 2788 diff -Naur vim72.orig/src/if_xcmdsrv.c vim72/src/if_xcmdsrv.c 2416 2789 --- vim72.orig/src/if_xcmdsrv.c 2008-07-18 06:05:03.000000000 -0700 2417 +++ vim72/src/if_xcmdsrv.c 2008-12- 20 15:01:23.000000000 -08002790 +++ vim72/src/if_xcmdsrv.c 2008-12-30 16:16:09.000000000 -0800 2418 2791 @@ -736,7 +736,7 @@ 2419 2792 + serverReply.ga_len; … … 2445 2818 diff -Naur vim72.orig/src/main.c vim72/src/main.c 2446 2819 --- vim72.orig/src/main.c 2008-07-24 01:40:56.000000000 -0700 2447 +++ vim72/src/main.c 2008-12- 20 15:02:13.000000000 -08002820 +++ vim72/src/main.c 2008-12-30 16:17:03.000000000 -0800 2448 2821 @@ -645,11 +645,12 @@ 2449 2822 … … 2507 2880 diff -Naur vim72.orig/src/mark.c vim72/src/mark.c 2508 2881 --- vim72.orig/src/mark.c 2008-08-08 15:06:49.000000000 -0700 2509 +++ vim72/src/mark.c 2008-12- 20 15:01:04.000000000 -08002882 +++ vim72/src/mark.c 2008-12-30 16:15:47.000000000 -0800 2510 2883 @@ -1627,15 +1627,17 @@ 2511 2884 … … 2576 2949 diff -Naur vim72.orig/src/mbyte.c vim72/src/mbyte.c 2577 2950 --- vim72.orig/src/mbyte.c 2008-07-14 05:38:05.000000000 -0700 2578 +++ vim72/src/mbyte.c 2008-12- 20 15:02:13.000000000 -08002951 +++ vim72/src/mbyte.c 2008-12-30 16:17:03.000000000 -0800 2579 2952 @@ -717,7 +717,7 @@ 2580 2953 * where mblen() returns 0 for invalid character. … … 2658 3031 diff -Naur vim72.orig/src/menu.c vim72/src/menu.c 2659 3032 --- vim72.orig/src/menu.c 2008-06-21 12:53:43.000000000 -0700 2660 +++ vim72/src/menu.c 2008-12- 20 14:59:42.000000000 -08003033 +++ vim72/src/menu.c 2008-12-30 16:14:07.000000000 -0800 2661 3034 @@ -1120,6 +1120,7 @@ 2662 3035 parent = menu; … … 2669 3042 diff -Naur vim72.orig/src/message.c vim72/src/message.c 2670 3043 --- vim72.orig/src/message.c 2008-07-09 11:24:55.000000000 -0700 2671 +++ vim72/src/message.c 2008-12- 20 15:02:13.000000000 -08003044 +++ vim72/src/message.c 2008-12-30 16:17:03.000000000 -0800 2672 3045 @@ -4585,61 +4585,62 @@ 2673 3046 if (remove_trailing_zeroes) … … 2756 3129 diff -Naur vim72.orig/src/misc1.c vim72/src/misc1.c 2757 3130 --- vim72.orig/src/misc1.c 2008-07-12 12:20:53.000000000 -0700 2758 +++ vim72/src/misc1.c 2008-12- 20 15:01:04.000000000 -08003131 +++ vim72/src/misc1.c 2008-12-30 16:15:47.000000000 -0800 2759 3132 @@ -3245,9 +3245,9 @@ 2760 3133 … … 2771 3144 diff -Naur vim72.orig/src/misc2.c vim72/src/misc2.c 2772 3145 --- vim72.orig/src/misc2.c 2008-07-23 12:12:56.000000000 -0700 2773 +++ vim72/src/misc2.c 2008-12- 20 15:01:15.000000000 -08003146 +++ vim72/src/misc2.c 2008-12-30 16:17:58.000000000 -0800 2774 3147 @@ -873,7 +873,7 @@ 2775 3148 /* 3. check for available memory: call mch_avail_mem() */ … … 2807 3180 /* 2808 3181 * Like vim_strsave(), but make all characters uppercase. 3182 @@ -2565,7 +2561,7 @@ 3183 int key; 3184 int dlen = 0; 3185 3186 - key = find_special_key(srcp, &modifiers, keycode); 3187 + key = find_special_key(srcp, &modifiers, keycode, FALSE); 3188 if (key == 0) 3189 return 0; 3190 3191 @@ -2601,10 +2597,11 @@ 3192 * returns 0 if there is no match. 3193 */ 3194 int 3195 -find_special_key(srcp, modp, keycode) 3196 +find_special_key(srcp, modp, keycode, keep_x_key) 3197 char_u **srcp; 3198 int *modp; 3199 - int keycode; /* prefer key code, e.g. K_DEL instead of DEL */ 3200 + int keycode; /* prefer key code, e.g. K_DEL instead of DEL */ 3201 + int keep_x_key; /* don't translate xHome to Home key */ 3202 { 3203 char_u *last_dash; 3204 char_u *end_of_name; 3205 @@ -2672,7 +2669,8 @@ 3206 else 3207 { 3208 key = get_special_key_code(last_dash + 1); 3209 - key = handle_x_keys(key); 3210 + if (!keep_x_key) 3211 + key = handle_x_keys(key); 3212 } 3213 3214 /* 2809 3215 diff -Naur vim72.orig/src/move.c vim72/src/move.c 2810 3216 --- vim72.orig/src/move.c 2008-07-12 09:26:47.000000000 -0700 2811 +++ vim72/src/move.c 2008-12- 20 15:01:35.000000000 -08003217 +++ vim72/src/move.c 2008-12-30 16:16:21.000000000 -0800 2812 3218 @@ -280,18 +280,20 @@ 2813 3219 … … 2859 3265 diff -Naur vim72.orig/src/netbeans.c vim72/src/netbeans.c 2860 3266 --- vim72.orig/src/netbeans.c 2008-07-13 09:19:54.000000000 -0700 2861 +++ vim72/src/netbeans.c 2008-12- 20 15:02:13.000000000 -08003267 +++ vim72/src/netbeans.c 2008-12-30 16:17:03.000000000 -0800 2862 3268 @@ -1043,7 +1043,7 @@ 2863 3269 nbdebug(("EVT: %s", buf)); … … 2897 3303 diff -Naur vim72.orig/src/normal.c vim72/src/normal.c 2898 3304 --- vim72.orig/src/normal.c 2008-07-31 13:03:08.000000000 -0700 2899 +++ vim72/src/normal.c 2008-12- 20 15:01:52.000000000 -08003305 +++ vim72/src/normal.c 2008-12-30 16:16:40.000000000 -0800 2900 3306 @@ -183,6 +183,8 @@ 2901 3307 static void nv_cursorhold __ARGS((cmdarg_T *cap)); … … 3085 3491 diff -Naur vim72.orig/src/ops.c vim72/src/ops.c 3086 3492 --- vim72.orig/src/ops.c 2008-06-21 13:08:59.000000000 -0700 3087 +++ vim72/src/ops.c 2008-12- 20 15:02:38.000000000 -08003493 +++ vim72/src/ops.c 2008-12-30 16:17:30.000000000 -0800 3088 3494 @@ -2209,12 +2209,15 @@ 3089 3495 { … … 3106 3512 diff -Naur vim72.orig/src/option.c vim72/src/option.c 3107 3513 --- vim72.orig/src/option.c 2008-07-18 06:05:33.000000000 -0700 3108 +++ vim72/src/option.c 2008-12- 20 15:02:13.000000000 -08003514 +++ vim72/src/option.c 2008-12-30 16:17:58.000000000 -0800 3109 3515 @@ -2593,13 +2593,13 @@ 3110 3516 #ifdef FEAT_VIMINFO … … 3153 3559 /* There's another character after zeros or the string 3154 3560 * is empty. In both cases, we are trying to set a 3561 @@ -8323,7 +8328,7 @@ 3562 { 3563 --arg; /* put arg at the '<' */ 3564 modifiers = 0; 3565 - key = find_special_key(&arg, &modifiers, TRUE); 3566 + key = find_special_key(&arg, &modifiers, TRUE, TRUE); 3567 if (modifiers) /* can't handle modifiers here */ 3568 key = 0; 3569 } 3155 3570 diff -Naur vim72.orig/src/os_unix.c vim72/src/os_unix.c 3156 3571 --- vim72.orig/src/os_unix.c 2008-08-06 04:01:40.000000000 -0700 3157 +++ vim72/src/os_unix.c 2008-12- 20 15:02:13.000000000 -08003572 +++ vim72/src/os_unix.c 2008-12-30 16:17:03.000000000 -0800 3158 3573 @@ -315,12 +315,15 @@ 3159 3574 {-1, "Unknown!", FALSE} … … 3269 3684 diff -Naur vim72.orig/src/proto/eval.pro vim72/src/proto/eval.pro 3270 3685 --- vim72.orig/src/proto/eval.pro 2008-08-09 07:31:25.000000000 -0700 3271 +++ vim72/src/proto/eval.pro 2008-12- 20 15:01:52.000000000 -08003686 +++ vim72/src/proto/eval.pro 2008-12-30 16:16:40.000000000 -0800 3272 3687 @@ -17,7 +17,7 @@ 3273 3688 int eval_to_bool __ARGS((char_u *arg, int *error, char_u **nextcmd, int skip)); … … 3311 3726 diff -Naur vim72.orig/src/proto/ex_cmds.pro vim72/src/proto/ex_cmds.pro 3312 3727 --- vim72.orig/src/proto/ex_cmds.pro 2008-08-09 07:31:25.000000000 -0700 3313 +++ vim72/src/proto/ex_cmds.pro 2008-12- 20 15:01:04.000000000 -08003728 +++ vim72/src/proto/ex_cmds.pro 2008-12-30 16:15:47.000000000 -0800 3314 3729 @@ -11,7 +11,7 @@ 3315 3730 char_u *make_filter_cmd __ARGS((char_u *cmd, char_u *itmp, char_u *otmp)); … … 3323 3738 diff -Naur vim72.orig/src/proto/ex_getln.pro vim72/src/proto/ex_getln.pro 3324 3739 --- vim72.orig/src/proto/ex_getln.pro 2008-08-09 07:31:28.000000000 -0700 3325 +++ vim72/src/proto/ex_getln.pro 2008-12- 20 15:02:01.000000000 -08003740 +++ vim72/src/proto/ex_getln.pro 2008-12-30 16:16:50.000000000 -0800 3326 3741 @@ -31,7 +31,7 @@ 3327 3742 void set_cmd_context __ARGS((expand_T *xp, char_u *str, int len, int col)); … … 3335 3750 diff -Naur vim72.orig/src/proto/mark.pro vim72/src/proto/mark.pro 3336 3751 --- vim72.orig/src/proto/mark.pro 2008-08-09 07:31:36.000000000 -0700 3337 +++ vim72/src/proto/mark.pro 2008-12- 20 15:01:04.000000000 -08003752 +++ vim72/src/proto/mark.pro 2008-12-30 16:15:47.000000000 -0800 3338 3753 @@ -26,5 +26,5 @@ 3339 3754 void write_viminfo_filemarks __ARGS((FILE *fp)); … … 3343 3758 +void copy_viminfo_marks __ARGS((vir_T *virp, FILE *fp_out, int count, int eof, int flags)); 3344 3759 /* vim: set ft=c : */ 3760 diff -Naur vim72.orig/src/proto/misc2.pro vim72/src/proto/misc2.pro 3761 --- vim72.orig/src/proto/misc2.pro 2008-08-09 07:31:40.000000000 -0700 3762 +++ vim72/src/proto/misc2.pro 2008-12-30 16:17:58.000000000 -0800 3763 @@ -59,7 +59,7 @@ 3764 int handle_x_keys __ARGS((int key)); 3765 char_u *get_special_key_name __ARGS((int c, int modifiers)); 3766 int trans_special __ARGS((char_u **srcp, char_u *dst, int keycode)); 3767 -int find_special_key __ARGS((char_u **srcp, int *modp, int keycode)); 3768 +int find_special_key __ARGS((char_u **srcp, int *modp, int keycode, int keep_x_key)); 3769 int extract_modifiers __ARGS((int key, int *modp)); 3770 int find_special_key_in_table __ARGS((int c)); 3771 int get_special_key_code __ARGS((char_u *name)); 3345 3772 diff -Naur vim72.orig/src/pty.c vim72/src/pty.c 3346 3773 --- vim72.orig/src/pty.c 2008-06-21 11:52:58.000000000 -0700 3347 +++ vim72/src/pty.c 2008-12- 20 14:59:39.000000000 -08003774 +++ vim72/src/pty.c 2008-12-30 16:14:03.000000000 -0800 3348 3775 @@ -270,9 +270,10 @@ 3349 3776 } … … 3361 3788 diff -Naur vim72.orig/src/screen.c vim72/src/screen.c 3362 3789 --- vim72.orig/src/screen.c 2008-07-24 07:45:07.000000000 -0700 3363 +++ vim72/src/screen.c 2008-12- 20 15:00:42.000000000 -08003790 +++ vim72/src/screen.c 2008-12-30 16:15:21.000000000 -0800 3364 3791 @@ -2439,9 +2439,17 @@ 3365 3792 … … 3385 3812 diff -Naur vim72.orig/src/spell.c vim72/src/spell.c 3386 3813 --- vim72.orig/src/spell.c 2008-07-12 12:20:55.000000000 -0700 3387 +++ vim72/src/spell.c 2008-12- 20 15:02:52.000000000 -08003814 +++ vim72/src/spell.c 2008-12-30 16:17:46.000000000 -0800 3388 3815 @@ -77,7 +77,7 @@ 3389 3816 … … 4220 4647 diff -Naur vim72.orig/src/structs.h vim72/src/structs.h 4221 4648 --- vim72.orig/src/structs.h 2008-07-30 13:02:50.000000000 -0700 4222 +++ vim72/src/structs.h 2008-12- 20 15:01:35.000000000 -08004649 +++ vim72/src/structs.h 2008-12-30 16:16:21.000000000 -0800 4223 4650 @@ -459,7 +459,7 @@ 4224 4651 typedef struct … … 4249 4676 diff -Naur vim72.orig/src/tag.c vim72/src/tag.c 4250 4677 --- vim72.orig/src/tag.c 2008-07-16 14:31:30.000000000 -0700 4251 +++ vim72/src/tag.c 2008-12- 20 15:02:50.000000000 -08004678 +++ vim72/src/tag.c 2008-12-30 16:17:42.000000000 -0800 4252 4679 @@ -2725,7 +2725,24 @@ 4253 4680 */ … … 4295 4722 diff -Naur vim72.orig/src/testdir/Make_ming.mak vim72/src/testdir/Make_ming.mak 4296 4723 --- vim72.orig/src/testdir/Make_ming.mak 1969-12-31 16:00:00.000000000 -0800 4297 +++ vim72/src/testdir/Make_ming.mak 2008-12- 20 15:00:39.000000000 -08004724 +++ vim72/src/testdir/Make_ming.mak 2008-12-30 16:15:18.000000000 -0800 4298 4725 @@ -0,0 +1,91 @@ 4299 4726 +# Makefile to run tests for Vim, on Dos-like machines … … 4390 4817 diff -Naur vim72.orig/src/testdir/Makefile vim72/src/testdir/Makefile 4391 4818 --- vim72.orig/src/testdir/Makefile 2008-06-19 13:29:46.000000000 -0700 4392 +++ vim72/src/testdir/Makefile 2008-12- 20 15:00:21.000000000 -08004819 +++ vim72/src/testdir/Makefile 2008-12-30 16:14:55.000000000 -0800 4393 4820 @@ -26,15 +26,17 @@ 4394 4821 … … 4424 4851 diff -Naur vim72.orig/src/testdir/test42.ok vim72/src/testdir/test42.ok 4425 4852 --- vim72.orig/src/testdir/test42.ok 2008-02-20 04:27:37.000000000 -0800 4426 +++ vim72/src/testdir/test42.ok 2008-12- 20 15:01:10.000000000 -08004853 +++ vim72/src/testdir/test42.ok 2008-12-30 16:15:53.000000000 -0800 4427 4854 @@ -20,7 +20,7 @@ 4428 4855 ucs-2 … … 4436 4863 diff -Naur vim72.orig/src/ui.c vim72/src/ui.c 4437 4864 --- vim72.orig/src/ui.c 2008-07-14 11:14:56.000000000 -0700 4438 +++ vim72/src/ui.c 2008-12- 20 15:02:13.000000000 -08004865 +++ vim72/src/ui.c 2008-12-30 16:17:03.000000000 -0800 4439 4866 @@ -1820,7 +1820,7 @@ 4440 4867 #ifdef HAVE_DUP … … 4544 4971 diff -Naur vim72.orig/src/version.c vim72/src/version.c 4545 4972 --- vim72.orig/src/version.c 2008-08-09 07:24:52.000000000 -0700 4546 +++ vim72/src/version.c 2008-12- 20 15:02:52.000000000 -08004547 @@ -677,9 +677,1 52@@4973 +++ vim72/src/version.c 2008-12-30 16:18:07.000000000 -0800 4974 @@ -677,9 +677,160 @@ 4548 4975 static int included_patches[] = 4549 4976 { /* Add new patch number below this line */ 4550 4977 /**/ 4978 + 76, 4979 +/**/ 4980 + 75, 4981 +/**/ 4982 + 73, 4983 +/**/ 4984 + 70, 4985 +/**/ 4551 4986 + 69, 4552 4987 +/**/ … … 4687 5122 + * Also add a comment marker to separate the lines. 4688 5123 + * See the official Vim patches for the diff format: It must use a context of 4689 + * one line only. Use "diff -C2".5124 + * one line only. Create it by hand or use "diff -C2" and edit the patch. 4690 5125 + */ 4691 5126 +static char *(extra_patches[]) = … … 4698 5133 highest_patch() 4699 5134 { 4700 @@ -786,7 +9 29,7 @@5135 @@ -786,7 +937,7 @@ 4701 5136 MSG_PUTS(_("\nRISC OS version")); 4702 5137 #endif … … 4707 5142 if (*compiled_arch != NUL) 4708 5143 { 4709 @@ -825,6 +9 68,19 @@5144 @@ -825,6 +976,19 @@ 4710 5145 } 4711 5146 } … … 4729 5164 diff -Naur vim72.orig/src/vim.h vim72/src/vim.h 4730 5165 --- vim72.orig/src/vim.h 2008-08-09 09:03:38.000000000 -0700 4731 +++ vim72/src/vim.h 2008-12- 20 15:01:49.000000000 -08005166 +++ vim72/src/vim.h 2008-12-30 16:16:37.000000000 -0800 4732 5167 @@ -341,8 +341,14 @@ 4733 5168 #ifdef BACKSLASH_IN_FILENAME … … 4789 5224 diff -Naur vim72.orig/src/window.c vim72/src/window.c 4790 5225 --- vim72.orig/src/window.c 2008-08-06 04:00:30.000000000 -0700 4791 +++ vim72/src/window.c 2008-12- 20 15:02:13.000000000 -08005226 +++ vim72/src/window.c 2008-12-30 16:17:03.000000000 -0800 4792 5227 @@ -4028,14 +4028,14 @@ 4793 5228 if (mch_dirname(cwd, MAXPATHL) == OK) … … 4810 5245 diff -Naur vim72.orig/src/workshop.c vim72/src/workshop.c 4811 5246 --- vim72.orig/src/workshop.c 2008-06-21 11:53:26.000000000 -0700 4812 +++ vim72/src/workshop.c 2008-12- 20 15:02:07.000000000 -08005247 +++ vim72/src/workshop.c 2008-12-30 16:16:56.000000000 -0800 4813 5248 @@ -1121,8 +1121,12 @@ 4814 5249 ? (char *)curbuf->b_sfname : "<None>");
Note:
See TracChangeset
for help on using the changeset viewer.