4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=ISO-8859-1
7 Content-Transfer-Encoding: 8bit
11 Problem: ":unlet v:this_session" causes a crash. (Marius Roets)
12 Solution: When trying to unlet a fixed variable give an error message.
16 *** ../vim-7.0.076/src/eval.c Tue Aug 29 21:59:25 2006
17 --- src/eval.c Sat Sep 2 13:43:20 2006
21 static void list_one_var_a __ARGS((char_u *prefix, char_u *name, int type, char_u *string));
22 static void set_var __ARGS((char_u *name, typval_T *varp, int copy));
23 static int var_check_ro __ARGS((int flags, char_u *name));
24 + static int var_check_fixed __ARGS((int flags, char_u *name));
25 static int tv_check_lock __ARGS((int lock, char_u *name));
26 static void copy_tv __ARGS((typval_T *from, typval_T *to));
27 static int item_copy __ARGS((typval_T *from, typval_T *to, int deep, int copyID));
31 hi = hash_find(ht, varname);
32 if (!HASHITEM_EMPTY(hi))
34 + if (var_check_fixed(HI2DI(hi)->di_flags, name))
36 if (var_check_ro(HI2DI(hi)->di_flags, name))
44 ! * Return TRUE if di_flags "flags" indicate read-only variable "name".
45 * Also give an error message.
52 ! * Return TRUE if di_flags "flags" indicates variable "name" is read-only.
53 * Also give an error message.
59 if ((flags & DI_FLAGS_RO_SBX) && sandbox)
61 EMSG2(_(e_readonlysbx), name);
68 + * Return TRUE if di_flags "flags" indicates variable "name" is fixed.
69 + * Also give an error message.
72 + var_check_fixed(flags, name)
76 + if (flags & DI_FLAGS_FIX)
78 + EMSG2(_("E795: Cannot delete variable %s"), name);
82 *** ../vim-7.0.076/src/version.c Tue Aug 29 22:35:11 2006
83 --- src/version.c Sat Sep 2 13:39:36 2006
87 { /* Add new patch number below this line */
93 ### Hiroshima 45, Chernobyl 86, Windows 95 ###
95 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
96 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
97 \\\ download, build and distribute -- http://www.A-A-P.org ///
98 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///