aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/optionstr.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/optionstr.c')
-rw-r--r--src/nvim/optionstr.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/nvim/optionstr.c b/src/nvim/optionstr.c
index bee08940b4..0d36634d9e 100644
--- a/src/nvim/optionstr.c
+++ b/src/nvim/optionstr.c
@@ -294,7 +294,6 @@ static void set_string_option_global(vimoption_T *opt, char **varp)
void set_string_option_direct(const char *name, int opt_idx, const char *val, int opt_flags,
int set_sid)
{
- char *s;
int both = (opt_flags & (OPT_LOCAL | OPT_GLOBAL)) == 0;
int idx = opt_idx;
@@ -315,7 +314,7 @@ void set_string_option_direct(const char *name, int opt_idx, const char *val, in
assert(opt->var != &p_shada);
- s = xstrdup(val);
+ char *s = xstrdup(val);
{
char **varp = (char **)get_varp_scope(opt, both ? OPT_LOCAL : opt_flags);
if ((opt_flags & OPT_FREE) && (opt->flags & P_ALLOCED)) {