Commit ca37ee67 authored by David Lawrence Ramsey's avatar David Lawrence Ramsey
Browse files

*really* fix the previous break_line() problem

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3024 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
No related merge requests found
Showing with 2 additions and 3 deletions
+2 -3
......@@ -575,10 +575,9 @@ ssize_t break_line(const char *line, ssize_t goal, bool newline)
assert(line != NULL);
while (*line != '\0' && goal >= 0) {
int pos;
size_t pos = 0;
line_len = parse_mbchar(line, NULL, NULL);
pos = mbwidth(line);
line_len = parse_mbchar(line, NULL, &pos);
if (is_blank_mbchar(line) || (newline && *line == '\n')) {
blank_loc = cur_loc;
......
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