# HG changeset patch # User Kim F. Storm # Date 1046176387 0 # Node ID 134f7d22f54aabe80bc24a23a22ffb5ce7c2f997 # Parent 975bc8dd31722dc3a49f38717d17fa644e8217ee (redisplay_window): Fix infinite loop in redisplay. If centering point failed to make whole line visible and vscroll is non-zero, disable vscroll and try centering point again. diff -r 975bc8dd3172 -r 134f7d22f54a src/xdisp.c --- a/src/xdisp.c Tue Feb 25 12:29:03 2003 +0000 +++ b/src/xdisp.c Tue Feb 25 12:33:07 2003 +0000 @@ -10822,6 +10822,14 @@ if (!make_cursor_line_fully_visible (w)) { + /* If vscroll is enabled, disable it and try again. */ + if (w->vscroll) + { + w->vscroll = 0; + clear_glyph_matrix (w->desired_matrix); + goto recenter; + } + /* If centering point failed to make the whole line visible, put point at the top instead. That has to make the whole line visible, if it can be done. */