Commit 0d847aad authored by David Lawrence Ramsey's avatar David Lawrence Ramsey
Browse files

handle wctomb() failure in parse_char() too

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2208 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
No related merge requests found
Showing with 2 additions and 0 deletions
+2 -0
......@@ -190,6 +190,8 @@ int parse_char(const char *str, int *chr, size_t *col
if (wctomb(ctrl_wide_str, (wchar_t)wide_str) != -1)
*col += wcwidth(wide_str);
else
(*col)++;
free(ctrl_wide_str);
/* If we have a normal character, get its width in columns
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment