summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan D. <jan.h.d@swipnet.se>2011-02-08 08:19:20 +0100
committerJan D. <jan.h.d@swipnet.se>2011-02-08 08:19:20 +0100
commit04f29be9f959fc60f58b51681dd4b19d207a3ae5 (patch)
tree5908aadc57c5b64765362245baae404794073697
parent55444d3764f842a68b3614277da511873f2ff38e (diff)
downloademacs-04f29be9f959fc60f58b51681dd4b19d207a3ae5.tar.gz
* nsterm.m (setFrame, initFrame): Make sure pixel_height doesn't become
zero.
-rw-r--r--src/ChangeLog5
-rw-r--r--src/nsterm.m2
2 files changed, 7 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 6eed5bcf7e3..2dda0a53b94 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,8 @@
+2011-02-08 Jan Djärv <jan.h.d@swipnet.se>
+
+ * nsterm.m (setFrame, initFrame): Make sure pixel_height doesn't become
+ zero (Bug#7348).
+
2011-02-03 Glenn Morris <rgm@gnu.org>
* xfaces.c (Finternal_set_lisp_face_attribute):
diff --git a/src/nsterm.m b/src/nsterm.m
index addb6d01d71..30b73c2fd13 100644
--- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -5721,6 +5721,7 @@ ns_term_shutdown (int sig)
win = nwin;
condemned = NO;
pixel_height = NSHeight (r);
+ if (pixel_height == 0) pixel_height = 1;
min_portion = 20 / pixel_height;
frame = XFRAME (XWINDOW (win)->frame);
@@ -5750,6 +5751,7 @@ ns_term_shutdown (int sig)
NSTRACE (EmacsScroller_setFrame);
/* BLOCK_INPUT; */
pixel_height = NSHeight (newRect);
+ if (pixel_height == 0) pixel_height = 1;
min_portion = 20 / pixel_height;
[super setFrame: newRect];
[self display];