From: Eli Zaretskii <eliz@gnu.org>
To: Zihao Zhu <all_but_last@163.com>
Cc: 41627@debbugs.gnu.org, pipcet@gmail.com
Subject: bug#41627: 28.0.50; Emacs with cairo build segfault in HELLO file
Date: Sun, 31 May 2020 20:24:41 +0300 [thread overview]
Message-ID: <83v9kcj9uu.fsf@gnu.org> (raw)
In-Reply-To: <0ac5574a-3e61-182c-406a-94500b66cca6@163.com> (message from Zihao Zhu on Sun, 31 May 2020 23:38:28 +0800)
> Cc: 41627@debbugs.gnu.org, Pip Cet <pipcet@gmail.com>
> From: Zihao Zhu <all_but_last@163.com>
> Date: Sun, 31 May 2020 23:38:28 +0800
>
> A gdb attached backtrace generated by Emacs build with CFLAGS=-O0 -g3 in
> attachment
Thanks, I think the situation is clear.
> 0x00000000006c5a34 in ftcrfont_open (f=0xc192d0, entity=0x1300675, pixel_size=18) at ftcrfont.c:237
> 237 ftcrfont.c: 没有那个文件或目录.
> #0 0x00000000006c5a34 in ftcrfont_open (f=0xc192d0, entity=0x1300675, pixel_size=18) at ftcrfont.c:237
This crashes here:
ft_face = cairo_ft_scaled_font_lock_face (scaled_font);
if (XFIXNUM (AREF (entity, FONT_SIZE_INDEX)) == 0)
{
int upEM = ft_face->units_per_EM; <<<<<<<<<<<<<<<<<<<<<
because cairo_ft_scaled_font_lock_face returned NULL:
> ft_face = 0x0
That function is documented to be able to return NULL:
Returns
The FT_Face object for font, scaled appropriately, or NULL if
scaled_font is in an error state (see cairo_scaled_font_status()) or
there is insufficient memory.
So it sounds like we should see if scaled_font is "in an error state",
and in any case bail out if ft_face is NULL.
Can someone please propose a patch along these lines? I cannot easily
test a Cairo build, so I won't try showing a patch.
Thanks.
next prev parent reply other threads:[~2020-05-31 17:24 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-31 11:32 bug#41627: 28.0.50; Emacs with cairo build segfault in HELLO file Zihao Zhu
2020-05-31 12:35 ` Pip Cet
2020-05-31 14:27 ` Zihao Zhu
2020-05-31 14:34 ` Pip Cet
2020-05-31 14:31 ` Zihao Zhu
2020-05-31 14:54 ` Eli Zaretskii
2020-05-31 15:38 ` Zihao Zhu
2020-05-31 17:24 ` Eli Zaretskii [this message]
2020-05-31 20:45 ` Pip Cet
2020-06-01 16:35 ` Eli Zaretskii
2020-06-01 18:02 ` Pip Cet
2020-09-27 14:29 ` Lars Ingebrigtsen
2020-10-21 15:58 ` Robert Pluim
2020-10-22 11:41 ` Lars Ingebrigtsen
2020-10-22 12:03 ` Zhu Zihao
2020-10-22 12:43 ` Lars Ingebrigtsen
2020-06-22 16:47 ` Zhu Zihao
2020-06-22 18:06 ` Eli Zaretskii
2020-06-23 4:10 ` bug#41627: " Zhu Zihao
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83v9kcj9uu.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=41627@debbugs.gnu.org \
--cc=all_but_last@163.com \
--cc=pipcet@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).