[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] emacs-25 21110af: Avoid assertion violations when renderin
From: |
Eli Zaretskii |
Subject: |
[Emacs-diffs] emacs-25 21110af: Avoid assertion violations when rendering some fonts |
Date: |
Wed, 29 Jun 2016 16:16:04 +0000 (UTC) |
branch: emacs-25
commit 21110afa2c6bc2698c172854988d306b9308d6f5
Author: Eli Zaretskii <address@hidden>
Commit: Eli Zaretskii <address@hidden>
Avoid assertion violations when rendering some fonts
* src/dispextern.h (FONT_TOO_HIGH): Don't consider a font "too
high" if its pixel_size value is zero. This avoids assertion
violations at the end of x_produce_glyphs.
---
src/dispextern.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/dispextern.h b/src/dispextern.h
index 7035872..7b9ae78 100644
--- a/src/dispextern.h
+++ b/src/dispextern.h
@@ -1541,7 +1541,8 @@ struct glyph_string
large vertical space. The heuristics is in the factor of 3. We
ignore the ascent and descent values reported by such fonts, and
instead go by the values reported for individual glyphs. */
-#define FONT_TOO_HIGH(ft) ((ft)->ascent + (ft)->descent > 3*(ft)->pixel_size)
+#define FONT_TOO_HIGH(ft) \
+ ((ft)->pixel_size > 0 && (ft)->ascent + (ft)->descent > 3*(ft)->pixel_size)
/***********************************************************************
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] emacs-25 21110af: Avoid assertion violations when rendering some fonts,
Eli Zaretskii <=