Avoid infloop in 'recenter'

* src/window.c (Frecenter): Avoid infinite loop in the minibuffer
under 'fido-vertical-mode'.  (Bug#56765)
This commit is contained in:
Eli Zaretskii 2022-07-25 21:59:55 +03:00
parent a866674b2a
commit 970190b844

View file

@ -6631,7 +6631,7 @@ and redisplay normally--don't erase and redraw the frame. */)
considered to be part of the visible height of the line.
*/
h += extra_line_spacing;
while (-it.current_y > h)
while (-it.current_y > h && it.what != IT_EOB)
move_it_by_lines (&it, 1);
charpos = IT_CHARPOS (it);