diff src/xdisp.c @ 42137:2eeaeb542d76

(window_box_height): Do not return negative values. From Gerd Moellmann <gerd@gnu.org>.
author Pavel Jan?k <Pavel@Janik.cz>
date Tue, 18 Dec 2001 16:14:13 +0000
parents c2bd9c005c06
children 0f4506820432
line wrap: on
line diff
--- a/src/xdisp.c	Tue Dec 18 16:04:56 2001 +0000
+++ b/src/xdisp.c	Tue Dec 18 16:14:13 2001 +0000
@@ -910,7 +910,9 @@
 	height -= estimate_mode_line_height (f, HEADER_LINE_FACE_ID);
     }
 
-  return height;
+  /* With a very small font and a mode-line that's taller than
+     default, we might end up with a negative height.  */
+  return max (0, height);
 }