unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Greg A. Woods" <woods@robohack.ca>
To: Eli Zaretskii <eliz@gnu.org>
Cc: GNU Emacs Bug Reports <53924@debbugs.gnu.org>
Subject: bug#53924: 26.1; fontification sometimes fails for some characters despite available glyphs
Date: Tue, 15 Feb 2022 14:04:56 -0800	[thread overview]
Message-ID: <m1nK5wO-0036s20@more.local> (raw)
In-Reply-To: <83zgms2oso.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 6872 bytes --]

At Tue, 15 Feb 2022 16:21:43 +0200, Eli Zaretskii <eliz@gnu.org> wrote:
Subject: Re: bug#53924: 26.1; fontification sometimes fails for some characters despite available glyphs
>
> Can you show a simple Emacs -Q invocation with that font which
> crashes?  Then I think I or someone else could look into the reasons.

I'll work on that.

In the mean time here's another crash in the exact same spot, but this
time triggered a new way, while trying to zoom the "*Font Families*"
window created by my test function with text-scale-adjust (C-x C-+).
Before zooming all the sample text for all fonts in the window was
viewable without any problem.

I still can't figure out, I think because of the inline function,
exactly which line within fontset_find_font() where the crash happens.

Perhaps I should rebuild with -O0?

(this is Emacs from yesterday's Git master, with the Lucid toolkit)


(gdb) source ../src/.gdbinit
SIGINT is used by the debugger.
Are you sure you want to change it? (y or n) [answered Y; input not from terminal]
DISPLAY = very.local:0
TERM = xterm-256color
Breakpoint 1 at 0xdcd800: file ../../src/emacs.c, line 408.
Breakpoint 2 at 0x4c7bdd: file ../../src/xterm.c, line 13072.
../src/.gdbinit:1375: Error in sourced command file:
Scripting in the "Python" language is not supported in this copy of GDB.
(gdb) run
Starting program: /work/woods/m-emacs/build-x86_64-nb9.99.81/src/emacs-29.0.50.1
[New LWP 17054 of process 7937]
[New process 7937]
Thread 1 "" received signal SIGSEGV, Segmentation fault.
fontset_find_font (fontset=fontset@entry=0xacb, c=c@entry=180,
    face=face@entry=0x7f04f5ec82c0, charset_id=charset_id@entry=-1,
    fallback=fallback@entry=false) at ../../src/lisp.h:757
757       return lisp_h_XLP (o);
(gdb) pp fontset
#<INVALID_LISP_OBJECT 0x00000acb>
(gdb) pp face
#<INVALID_LISP_OBJECT 0x7f04f5ec82c0>
(gdb) print fontset
$1 = (Lisp_Object) 0xacb
(gdb) print face
$2 = (struct face *) 0x7f04f5ec82c0
(gdb) print *fontset
$4 = <incomplete type>
(gdb) print *face
$3 = {lface = {0x63f0, 0x7f05110cd184, 0x7f0515df8dc4, 0xb2e0, 0x26e, 0xa170,
    0x7f05133441b0, 0x0, 0x0, 0x7f0515e54404, 0x7f0515e54424, 0x0, 0x0, 0x0, 0x0,
    0x7f0512221465, 0x0, 0x7f0511de0864, 0xf480, 0x0}, id = 4121, gc = 0x0, stipple = 0,
  foreground = 0, background = 16777215, underline_color = 0, overline_color = 0,
  strike_through_color = 0, box_color = 0, font = 0x0, fontset = -1,
  box_vertical_line_width = 0, box_horizontal_line_width = 0,
  underline_pixels_above_descent_line = 0, box = FACE_NO_BOX,
  underline = FACE_NO_UNDERLINE, use_box_color_for_shadows_p = false,
  overline_p = false, strike_through_p = false, foreground_defaulted_p = false,
  background_defaulted_p = false, underline_defaulted_p = false,
  overline_color_defaulted_p = false, strike_through_color_defaulted_p = false,
  box_color_defaulted_p = false, underline_at_descent_line_p = false,
  tty_bold_p = false, tty_italic_p = false, tty_underline_p = false,
  tty_reverse_p = false, tty_strike_through_p = false, colors_copied_bitwise_p = false,
  overstrike = false, hash = 34914959679024, next = 0x7f04fbd65a40, prev = 0x0,
  ascii_face = 0x7f04f5ec82c0, extra = 0x0}
(gdb) info locals
vec = <optimized out>
font_group = <optimized out>
i = <optimized out>
charset_matched = 0
found_index = <optimized out>
f = <optimized out>
rfont_def = <optimized out>
(gdb) bt
#0  fontset_find_font (fontset=fontset@entry=0xacb, c=c@entry=180,
    face=face@entry=0x7f04f5ec82c0, charset_id=charset_id@entry=-1,
    fallback=fallback@entry=false) at ../../src/lisp.h:757
#1  0x00000000005ee5dd in fontset_font (fontset=fontset@entry=0xacb, c=c@entry=180,
    face=face@entry=0x7f04f5ec82c0, id=-1) at ../../src/fontset.c:766
#2  0x00000000005eec55 in face_for_char (f=0x7f051297e9e0,
    face=face@entry=0x7f04f5ec82c0, c=180, pos=<optimized out>, object=<optimized out>)
    at ../../src/fontset.c:996
#3  0x0000000000436fd2 in FACE_FOR_CHAR (object=<optimized out>, pos=<optimized out>,
    character=<optimized out>, face=0x7f04f5ec82c0, f=<optimized out>)
    at ../../src/dispextern.h:1908
#4  get_next_display_element (it=it@entry=0x7f7fffb88b10) at ../../src/xdisp.c:8012
#5  0x000000000043e326 in display_line (it=it@entry=0x7f7fffb88b10,
    cursor_vpos=cursor_vpos@entry=0) at ../../src/xdisp.c:24105
#6  0x00000000004437fa in try_window (window=window@entry=0x7f0508317cfd, pos=...,
    flags=flags@entry=1) at ../../src/xdisp.c:20009
#7  0x0000000000461bc8 in redisplay_window (window=0x7f0508317cfd,
    just_this_one_p=just_this_one_p@entry=false) at ../../src/xdisp.c:19416
#8  0x0000000000463881 in redisplay_window_0 (window=window@entry=0x7f0508317cfd)
    at ../../src/xdisp.c:17061
#9  0x0000000000572a8e in internal_condition_case_1 (
    bfun=bfun@entry=0x463858 <redisplay_window_0>, arg=arg@entry=0x7f0508317cfd,
    handlers=<optimized out>, hfun=hfun@entry=0x417fee <redisplay_window_error>)
    at ../../src/eval.c:1503
#10 0x000000000041ab68 in redisplay_windows (window=0x7f0508317cfd)
    at ../../src/xdisp.c:17041
#11 0x000000000044cb8f in redisplay_internal () at ../../src/xdisp.c:16509
#12 0x000000000044df61 in redisplay () at ../../src/xdisp.c:15719
#13 0x0000000000502cb8 in read_char (commandflag=commandflag@entry=1,
    map=map@entry=0x7f051157e083, prev_event=0x0,
    used_mouse_menu=used_mouse_menu@entry=0x7f7fffb8dbfb, end_time=end_time@entry=0x0)
    at ../../src/keyboard.c:2586
#14 0x000000000050448f in read_key_sequence (keybuf=keybuf@entry=0x7f7fffb8dd10,
    prompt=prompt@entry=0x0, dont_downcase_last=dont_downcase_last@entry=false,
    can_return_switch_frame=can_return_switch_frame@entry=true,
    fix_current_buffer=fix_current_buffer@entry=true,
    prevent_redisplay=prevent_redisplay@entry=false) at ../../src/keyboard.c:9778
#15 0x0000000000505f82 in command_loop_1 () at ../../src/lisp.h:1153
#16 0x0000000000572a08 in internal_condition_case (
    bfun=bfun@entry=0x505d75 <command_loop_1>, handlers=handlers@entry=0x90,
    hfun=hfun@entry=0x4fa596 <cmd_error>) at ../../src/eval.c:1479
#17 0x00000000004f3f97 in command_loop_2 (handlers=handlers@entry=0x90)
    at ../../src/keyboard.c:1137
#18 0x000000000057296e in internal_catch (tag=tag@entry=0xe9d0,
--Type <RET> for more, q to quit, c to continue without paging--
    func=func@entry=0x4f3f81 <command_loop_2>, arg=arg@entry=0x90)
    at ../../src/eval.c:1210
#19 0x00000000004f3f50 in command_loop () at ../../src/lisp.h:1153
#20 0x00000000004fa1da in recursive_edit_1 () at ../../src/keyboard.c:724
#21 0x00000000004fa4ef in Frecursive_edit () at ../../src/keyboard.c:807
#22 0x0000000000dd55d7 in main (argc=2, argv=0x7f7fffb8e098) at ../../src/emacs.c:2430
(gdb)

--
					Greg A. Woods <gwoods@acm.org>

Kelowna, BC     +1 250 762-7675           RoboHack <woods@robohack.ca>
Planix, Inc. <woods@planix.com>     Avoncote Farms <woods@avoncote.ca>

[-- Attachment #2: OpenPGP Digital Signature --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

  reply	other threads:[~2022-02-15 22:04 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-10 19:02 bug#53924: 26.1; fontification sometimes fails for some characters despite available glyphs Greg A. Woods
2022-02-10 20:21 ` Eli Zaretskii
2022-02-10 23:34   ` Greg A. Woods
2022-02-11  7:15     ` Eli Zaretskii
2022-02-11 21:56       ` Greg A. Woods
2022-02-13  6:06       ` Greg A. Woods
2022-02-13 11:53         ` Eli Zaretskii
2022-02-15  2:01           ` Greg A. Woods
2022-02-15 14:21             ` Eli Zaretskii
2022-02-15 22:04               ` Greg A. Woods [this message]
2022-02-16  2:32               ` Greg A. Woods
2022-02-16  3:36                 ` Eli Zaretskii
2022-02-16 21:55                   ` Greg A. Woods
2022-02-16 22:14                 ` Lars Ingebrigtsen
     [not found] ` <handler.53924.B.164452023325832.ack@debbugs.gnu.org>
2022-02-10 22:42   ` Greg A. Woods

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=m1nK5wO-0036s20@more.local \
    --to=woods@robohack.ca \
    --cc=53924@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    /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).