mirror of
git://git.sv.gnu.org/nano.git
synced 2024-11-30 00:23:28 +03:00
tweaks: free an option string also when it was invalid
This commit is contained in:
parent
59edef55dc
commit
eca6faee5b
@ -1147,10 +1147,9 @@ void parse_rcfile(FILE *rcstream, bool syntax_only)
|
||||
rcfile_error(N_("Requested fill size \"%s\" is invalid"),
|
||||
option);
|
||||
wrap_at = -CHARS_FROM_EOL;
|
||||
} else {
|
||||
} else
|
||||
UNSET(NO_WRAP);
|
||||
free(option);
|
||||
}
|
||||
free(option);
|
||||
} else
|
||||
#endif
|
||||
#ifndef NANO_TINY
|
||||
@ -1211,8 +1210,8 @@ void parse_rcfile(FILE *rcstream, bool syntax_only)
|
||||
rcfile_error(N_("Requested tab size \"%s\" is invalid"),
|
||||
option);
|
||||
tabsize = -1;
|
||||
} else
|
||||
free(option);
|
||||
}
|
||||
free(option);
|
||||
} else
|
||||
assert(FALSE);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user