Fixed memory leak in ":ownsyntax".
diff --git a/src/eval.c b/src/eval.c
index ca9389f..2e5b876 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -3884,11 +3884,6 @@
++hi;
return cat_prefix_varname('w', hi->hi_key);
}
- if (wdone == ht->ht_used)
- {
- ++wdone;
- return (char_u *)"w:ownsyntax";
- }
#ifdef FEAT_WINDOWS
/* t: variables */
@@ -18758,18 +18753,6 @@
tv = &atv;
}
- if (STRCMP(name, "w:ownsyntax") == 0)
- {
- atv.v_type = VAR_NUMBER;
-#ifdef FEAT_SYN_HL
- atv.vval.v_number = (curwin->w_s != &curwin->w_buffer->b_s) ? 1 : 0;
-#else
- atv.vval.v_number = 0;
-#endif
- tv = &atv;
- }
-
-
/*
* Check for user-defined variables.
*/
@@ -19292,6 +19275,7 @@
/*
* Get the string value of a (global/local) variable.
+ * Note: see get_tv_string() for how long the pointer remains valid.
* Returns NULL when it doesn't exist.
*/
char_u *