aboutsummaryrefslogtreecommitdiffstats
path: root/src/xdisp.c
diff options
context:
space:
mode:
authorPavel Janík <[email protected]>2001-12-18 16:16:14 +0000
committerPavel Janík <[email protected]>2001-12-18 16:16:14 +0000
commit7c75be3651fd90d159d12c6d7871e0cc6e94a522 (patch)
treecc97e541df2b55a9e0232b6aeac0721ed243841c /src/xdisp.c
parent3e16e035c5fad0eab8ee2b84ee175bcc16b46736 (diff)
(window_box_height): Do not return negative values.
From Gerd Moellmann <[email protected]>.
Diffstat (limited to 'src/xdisp.c')
-rw-r--r--src/xdisp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/xdisp.c b/src/xdisp.c
index b2a5a1d08a..1dd5f0fa98 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -910,7 +910,9 @@ window_box_height (w)
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);
}