+ /* Adjust the terminal height for any overlap, so that
+ * no lines get lost off the top. */
+ if (len >= terminal_width) {
+ div_t result = div( len, terminal_width);
+ if (result.quot) {
+ if (result.rem)
+ page_height-=result.quot;
+ else
+ page_height-=(result.quot-1);
+ }
+ }
+ if (++lines >= page_height) {