diff --git a/ChangeLog b/ChangeLog index 5ef478222e14c6ee87ab6dc6deaf4240b8a348bc..281c288ea617aa9e82daac7c07df0c3542dd729b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -33,8 +33,8 @@ CVS code - unnecessary update, and remove an unneeded clearok(FALSE). (DLR) do_output() - - Fix off-by-one error that allowed wrapping when we inserted a - tab, for Pico compatibility. (DLR) + - Properly allow wrapping when we insert a tab, for consistency. + (DLR) - utils.c: num_of_digits() - Use a size_t instead of an int, and rename to digits(). (DLR) diff --git a/src/nano.c b/src/nano.c index 01c475ecc679459fa26bf54b88abc50dbf20e756..f27fbefeddb86a2cbb15f6262b4a7cfe7e1d7206 100644 --- a/src/nano.c +++ b/src/nano.c @@ -3927,9 +3927,8 @@ void do_output(char *output, size_t output_len, bool allow_cntrls) do_right(FALSE); #ifndef DISABLE_WRAPPING - /* If we're wrapping text and we didn't insert a tab, we need to - * call edit_refresh(). */ - if (!ISSET(NO_WRAP) && output[i - 1] != '\t') { + /* If we're wrapping text, we need to call edit_refresh(). */ + if (!ISSET(NO_WRAP)) { bool do_refresh_save = do_refresh; do_refresh = do_wrap(current);