(render_edit_text): fix endless loop.

Thanks Sebastian Gniazdowski <sgniazdowski@gmail.com> for the issue.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Andrew Borodin 2021-06-27 15:02:14 +03:00
parent a81f1ca190
commit 7ef1925a98

View File

@ -921,10 +921,9 @@ render_edit_text (WEdit * edit, long start_row, long start_column, long end_row,
{
long upto;
row = start_row;
b = edit->start_display;
upto = MIN (curs_row - 1, end_row);
while (row <= upto)
for (row = start_row; row <= upto; row++)
{
if (key_pending (edit))
return;