Subject: bug#55068: 29.0.50; crashes when trying to set default font

From: Lars Ingebrigtsen <[email-masked]>
Date: Mon, 23 May 2022 14:19:52 +0200

Po Lu <[email-masked]> writes:

> If you can show a backtrace that actually displays something meaningful
> (or run Emacs under a memory checker such as Valgrind), that would be
> great.  The last one obtained from this crash ended with a segfault in
> SPECPDL_INDEX, which makes no sense.

Not very meaningful backtrace:

Thread 0x7fffeaf57640 (LWP 3291815) exited]

--Type <RET> for more, q to quit, c to continue without paging--
Thread 1 "emacs" received signal SIGSEGV, Segmentation fault.
x_menu_show (f=0x55555613a728, x=0, y=0, menuflags=0, 
    title=XIL(0x7ffff191a51c), error_name=0x7fffffffc140) at xmenu.c:1903
1903	  specpdl_ref specpdl_count = SPECPDL_INDEX ();
(gdb) bt
#0  x_menu_show
    (f=0x55555613a728, x=0, y=0, menuflags=0, title=XIL(0x7ffff191a51c), error_name=0x7fffffffc140) at xmenu.c:1903
#1  0x000055555562e00a in x_popup_menu_1
    (position=XIL(0x555555dc4c93), menu=XIL(0x5555569231e3)) at menu.c:1402
#2  0x000055555562e089 in Fx_popup_menu
    (position=XIL(0x555555dc4c93), menu=XIL(0x5555569231e3)) at menu.c:1466
#3  0x00005555557e4997 in funcall_subr
    (subr=0x555555c95360 <Sx_popup_menu>, numargs=2, args=0x7ffff0e561a8)
    at eval.c:2957
#4  0x0000555555836735 in exec_byte_code
    (fun=XIL(0x7ffff1694965), args_template=513, nargs=1, args=0x7ffff0e562b0)
    at bytecode.c:809
#5  0x00005555557e4c82 in fetch_and_exec_byte_code
    (fun=XIL(0x7ffff1999585), args_template=0, nargs=0, args=0x7fffffffc840)
    at eval.c:3004
#6  0x00005555557e4ff6 in funcall_lambda
    (fun=XIL(0x7ffff1999585), nargs=0, arg_vector=0x7fffffffc840)
    at eval.c:3076
#7  0x00005555557e4e14 in apply_lambda
    (fun=XIL(0x7ffff1999585), args=XIL(0), count=...) at eval.c:3026
#8  0x00005555557e350b in eval_sub (form=XIL(0x555555e0c583)) at eval.c:2467
#9  0x00005555557e2afd in Feval (form=XIL(0x555555e0c583), lexical=XIL(0))
--Type <RET> for more, q to quit, c to continue without paging--c
    at eval.c:2278
#10 0x00005555557e4997 in funcall_subr (subr=0x555555ca2820 <Seval>, numargs=2, args=0x7ffff0e56150) at eval.c:2957
#11 0x0000555555836735 in exec_byte_code (fun=XIL(0x7ffff162b32d), args_template=513, nargs=2, args=0x7ffff0e562d0) at bytecode.c:809
#12 0x00005555557e4c82 in fetch_and_exec_byte_code (fun=XIL(0x7ffff17f4af5), args_template=257, nargs=1, args=0x7fffffffd210) at eval.c:3004
#13 0x00005555557e4ff6 in funcall_lambda (fun=XIL(0x7ffff17f4af5), nargs=1, arg_vector=0x7fffffffd210) at eval.c:3076
#14 0x00005555557e456b in funcall_general (fun=XIL(0x7ffff17f4af5), numargs=1, args=0x7fffffffd210) at eval.c:2867
#15 0x00005555557e47c7 in Ffuncall (nargs=2, args=0x7fffffffd208) at eval.c:2917
#16 0x00005555557da894 in Ffuncall_interactively (nargs=2, args=0x7fffffffd208) at callint.c:260
#17 0x00005555557e4bae in funcall_subr (subr=0x555555ca2020 <Sfuncall_interactively>, numargs=2, args=0x7fffffffd208) at eval.c:2982
#18 0x00005555557e451f in funcall_general (fun=XIL(0x555555ca2025), numargs=2, args=0x7fffffffd208) at eval.c:2863
#19 0x00005555557e47c7 in Ffuncall (nargs=3, args=0x7fffffffd200) at eval.c:2917
#20 0x00005555557dcca7 in Fcall_interactively (function=XIL(0x2aaa9bad8100), record_flag=XIL(0), keys=XIL(0x7ffff1cb2c25)) at callint.c:798
#21 0x00005555557e49ca in funcall_subr (subr=0x555555ca2060 <Scall_interactively>, numargs=3, args=0x7ffff0e56070) at eval.c:2959
#22 0x0000555555836735 in exec_byte_code (fun=XIL(0x7ffff1657f2d), args_template=1025, nargs=1, args=0x7fffffffdb90) at bytecode.c:809
#23 0x00005555557e4c82 in fetch_and_exec_byte_code (fun=XIL(0x7ffff1657f2d), args_template=1025, nargs=1, args=0x7fffffffdb88) at eval.c:3004
#24 0x00005555557e4ff6 in funcall_lambda (fun=XIL(0x7ffff1657f2d), nargs=1, arg_vector=0x7fffffffdb88) at eval.c:3076
#25 0x00005555557e456b in funcall_general (fun=XIL(0x7ffff1657f2d), numargs=1, args=0x7fffffffdb88) at eval.c:2867
#26 0x00005555557e47c7 in Ffuncall (nargs=2, args=0x7fffffffdb80) at eval.c:2917
#27 0x000055555571f0a5 in call1 (fn=XIL(0x4a10), arg1=XIL(0x2aaa9bad8100)) at /home/larsi/src/emacs/trunk/src/lisp.h:3228
#28 0x000055555572203b in command_loop_1 () at keyboard.c:1512
#29 0x00005555557e0da2 in internal_condition_case (bfun=0x55555572182a <command_loop_1>, handlers=XIL(0x90), hfun=0x555555720e32 <cmd_error>) at eval.c:1452
#30 0x00005555557214da in command_loop_2 (handlers=XIL(0x90)) at keyboard.c:1140
#31 0x00005555557e0475 in internal_catch (tag=XIL(0xf5d0), func=0x5555557214b0 <command_loop_2>, arg=XIL(0x90)) at eval.c:1182
#32 0x000055555572146c in command_loop () at keyboard.c:1118
#33 0x00005555557209d4 in recursive_edit_1 () at keyboard.c:727
#34 0x0000555555720b80 in Frecursive_edit () at keyboard.c:810
#35 0x000055555571ce9e in main (argc=5, argv=0x7fffffffe0c8) at emacs.c:2488
Cannot access memory at address 0x7ffffec324ff
(gdb) 

I'll try valgrind next.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no