feedback: drop an unnecessary warning, to not bother the user

The idea of the warning was that `row < 0 || row >= editwinrows` would
never be true: that the check was redundant and could be removed.

As it appears to be too hard to make sure in advance that a chunk will
not fall outside the viewport, just drop the warning and leave the check
in place.

This also addresses https://savannah.gnu.org/bugs/?64168.
Reported-by: Matteo Raso <matteo_luigi_raso@protonmail.com>
This commit is contained in:
Benno Schulenberg 2024-03-30 11:03:50 +01:00
parent 17abce073f
commit 8610857015

View File

@ -2914,11 +2914,8 @@ int update_softwrapped_line(linestruct *line)
}
/* If the first chunk is offscreen, don't even try to display it. */
if (row < 0 || row >= editwinrows) {
statusline(ALERT, "Badness: tried to display a chunk on row %i"
" -- please report a bug", row);
if (row < 0 || row >= editwinrows)
return 0;
}
starting_row = row;