mirror of
git://git.sv.gnu.org/nano.git
synced 2024-11-22 04:41:21 +03:00
justify: reduce the character count when trimming trailing spaces
This fixes https://savannah.gnu.org/bugs/?50379.
This commit is contained in:
parent
23c3fd9bcd
commit
de3260cdb1
@ -2445,10 +2445,11 @@ void do_justify(bool full_justify)
|
||||
#endif
|
||||
|
||||
/* Break the current line. */
|
||||
if (ISSET(JUSTIFY_TRIM)) {
|
||||
if (ISSET(JUSTIFY_TRIM)) {
|
||||
while (break_pos > 0 &&
|
||||
is_blank_mbchar(&openfile->current->data[break_pos - 1])) {
|
||||
break_pos--;
|
||||
openfile->totsize--;
|
||||
}
|
||||
}
|
||||
null_at(&openfile->current->data, break_pos);
|
||||
|
Loading…
Reference in New Issue
Block a user