Package: emacs;
Reported by: Andrew Cohen <acohen <at> ust.hk>
Date: Tue, 28 Jan 2025 07:09:02 UTC
Severity: normal
Found in version 31.0.50
Done: Pip Cet <pipcet <at> protonmail.com>
To reply to this bug, email your comments to 75905 AT debbugs.gnu.org.
There is no need to reopen the bug first.
Toggle the display of automated, internal messages from the tracker.
View this report as an mbox folder, status mbox, maintainer mbox
bug-gnu-emacs <at> gnu.org
:bug#75905
; Package emacs
.
(Tue, 28 Jan 2025 07:09:02 GMT) Full text and rfc822 format available.Andrew Cohen <acohen <at> ust.hk>
:bug-gnu-emacs <at> gnu.org
.
(Tue, 28 Jan 2025 07:09:02 GMT) Full text and rfc822 format available.Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
From: Andrew Cohen <acohen <at> ust.hk> To: bug-gnu-emacs <at> gnu.org Subject: 31.0.50; feature/igc: crash when clicking menubar Date: Tue, 28 Jan 2025 15:02:54 +0800
pgtk emacs with mpc crashes whenever the menubar is clicked. Same configuration without igc has no problem. Thread 1 "emacs" received signal SIGABRT, Aborted. __pthread_kill_implementation (threadid=<optimized out>, signo=signo <at> entry=6, no_tid=no_tid <at> entry=0) at ./nptl/pthread_kill.c:44 warning: 44 ./nptl/pthread_kill.c: No such file or directory (gdb) bt full #0 __pthread_kill_implementation (threadid=<optimized out>, signo=signo <at> entry=6, no_tid=no_tid <at> entry=0) at ./nptl/pthread_kill.c:44 tid = <optimized out> ret = 0 pd = <optimized out> old_mask = {__val = {140737488338656}} ret = <optimized out> #1 0x00007ffff1f1ddef in __pthread_kill_internal (threadid=<optimized out>, signo=6) at ./nptl/pthread_kill.c:78 #2 0x00007ffff1ec9d02 in __GI_raise (sig=6) at ../sysdeps/posix/raise.c:26 ret = <optimized out> #3 0x000055555574f608 in terminate_due_to_signal (sig=6, backtrace_limit=2147483647) at emacs.c:470 #4 0x00005555557f8d86 in die (msg=0x555555a3a7c0 "((((struct vectorlike_header *) ((uintptr_t) ((void *) (globals.f_Vmenu_updating_frame).i) - (uintptr_t) ((Lisp_Word_tag) (Lisp_Vectorlike) << (1 ? 0 : VALBITS)))) ->size) & (PSEUDOVECTOR_FLAG | PVEC_"..., file=0x555555a3a76a "pgtkmenu.c", line=252) at alloc.c:8388 #5 0x0000555555972366 in set_frame_menubar (f=0x5555565996b0, deep_p=true) at pgtkmenu.c:252 menubar_widget = 0x20 items = {i = 0xa5648a0d0} wv = 0x7fffdef75c90 first_wv = 0x0 prev_wv = 0x0 i = 21845 submenu_start = 0x7fffdef86498 submenu_end = 0x555555971bf0 <FRAMEP+29> submenu_top_level_items = 0x7fffdef75c95 submenu_n_panes = 0x7fffdef8649b #6 0x000055555573e222 in menu_bar_button_pressed_cb (widget=0x55555663e0a0, event=0x555556393440, user_data=0x5555565996b0) at gtkutil.c:3373 f = 0x5555565996b0 #7 0x00007ffff7697caa in ??? () at /lib/x86_64-linux-gnu/libgtk-3.so.0 #8 0x00007ffff71049c0 in g_closure_invoke () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0 #9 0x00007ffff7118d43 in ??? () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0 #10 0x00007ffff711a032 in ??? () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0 #11 0x00007ffff7120626 in g_signal_emit_valist () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0 #12 0x00007ffff71206e3 in g_signal_emit () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0 #13 0x00007ffff79551cc in ??? () at /lib/x86_64-linux-gnu/libgtk-3.so.0 #14 0x00007ffff7805dae in ??? () at /lib/x86_64-linux-gnu/libgtk-3.so.0 #15 0x00007ffff7807b76 in gtk_main_do_event () at /lib/x86_64-linux-gnu/libgtk-3.so.0 #16 0x00007ffff7ed4ce9 in ??? () at /lib/x86_64-linux-gnu/libgdk-3.so.0 #17 0x00007ffff7f09096 in ??? () at /lib/x86_64-linux-gnu/libgdk-3.so.0 #18 0x00007ffff6ff193f in ??? () at /lib/x86_64-linux-gnu/libglib-2.0.so.0 #19 0x00007ffff6ff4238 in g_main_context_dispatch () at /lib/x86_64-linux-gnu/libglib-2.0.so.0 #20 0x00005555559607f5 in pgtk_read_socket (terminal=0x7fffdef754c8, hold_quit=0x7fffffffc940) at pgtkterm.c:3892 context = 0x55555630b550 context_acquired = true count = 0 #21 0x000055555576950f in gobble_input () at keyboard.c:7937 nr = 0 hold_quit = {kind = NO_EVENT, part = scroll_bar_nowhere, code = 0, modifiers = 0, x = {i = 0x0}, y = {i = 0x0}, timestamp = 0, frame_or_window = {i = 0x0}, arg = {i = 0x0}, device = {i = 0x38}} next = 0x0 nread = 0 err = false t = 0x7fffdef754c8 #22 0x00005555557699a7 in handle_async_input () at keyboard.c:8176 nread = 16809983 #23 0x00005555557699c6 in process_pending_signals () at keyboard.c:8190 #24 0x0000555555769a10 in unblock_input_to (level=0) at keyboard.c:8207 #25 0x0000555555769a34 in unblock_input () at keyboard.c:8226 #26 0x000055555576173c in timer_check () at keyboard.c:4879 nexttime = {tv_sec = 140737488341632, tv_nsec = 93824994344894} timers = {i = 0x7fffdf1e47cb} idle_timers = {i = 0x7fffdf1e47fb} tem = {i = 0x0} #27 0x000055555575ec37 in readable_events (flags=1) at keyboard.c:3612 #28 0x00005555557693d7 in get_input_pending (flags=1) at keyboard.c:7887 #29 0x0000555555771c14 in detect_input_pending_run_timers (do_display=true) at keyboard.c:11593 old_timers_run = 7 #30 0x00005555558b980d in wait_reading_process_output (time_limit=30, nsecs=0, read_kbd=-1, do_display=true, wait_for_cell=..., wait_proc=0x0, just_wait_proc=0) at process.c:5857 leave = false process_skipped = false wrapped = true channel_start = 0 child_fd = -1 last_read_channel = -1 channel = 1024 nfds = 1 Available = {fds_bits = {16, 0 <repeats 15 times>}} Writeok = {fds_bits = {0 <repeats 16 times>}} check_write = true check_delay = 0 no_avail = false xerrno = 11 proc = {i = 0x7ffff7059deb} timeout = {tv_sec = 0, tv_nsec = 0} end_time = {tv_sec = 1738047346, tv_nsec = 697950263} timer_delay = {tv_sec = 0, tv_nsec = 490501493} got_output_end_time = {tv_sec = 1738047346, tv_nsec = 697950263} wait = TIMEOUT got_some_output = -1 prev_wait_proc_nbytes_read = 0 retry_for_async = false count = {bytes = 128} now = {tv_sec = 0, tv_nsec = -1} #31 0x00005555555feb45 in sit_for (timeout=..., reading=true, display_option=1) at dispnew.c:6904 sec = 30 nsec = 0 do_display = true curbuf_eq_winbuf = true nbytes = 21845 #32 0x000055555575cc0f in read_char (commandflag=1, map=..., prev_event=..., used_mouse_menu=0x7fffffffd3bf, end_time=0x0) at keyboard.c:2936 tem0 = {i = 0x0} timeout = 30 count1 = {bytes = 96} delay_level = 4 buffer_size = 1 c = {i = 0x0} local_getcjmp = {{__jmpbuf = {0, 4847969625357113922, 0, 140737488346032, 140737354125312, 93824998019608, 4847969626034494018, 1590377205508430402}, __mask_was_saved = 0, __saved_mask = {__val = {93824996051544, 142068, 24, 12884901912, 140736936182480, 12921271309, 1, 140737488343632, 93824996083916, 0, 140736927922560, 17179857584, 24, 140736936182480, 1444967664, 17179857520}}}} save_jump = {{__jmpbuf = {0, 0, 0, 0, 0, 0, 0, 0}, __mask_was_saved = 0, __saved_mask = {__val = {0 <repeats 16 times>}}}} tem = {i = 0x0} save = {i = 0x0} previous_echo_area_message = {i = 0x0} also_record = {i = 0x0} reread = false recorded = false polling_stopped_here = false orig_kboard = 0x555556425e50 jmpcount = {bytes = 96} c_volatile = {i = 0x0} #33 0x000055555576fcfe in read_key_sequence (keybuf=0x7fffffffd560, prompt=..., dont_downcase_last=false, can_return_switch_frame=true, fix_current_buffer=true, prevent_redisplay=false, disable_text_conversion_p=false) at keyboard.c:10763 interrupted_kboard = 0x555556425e50 interrupted_frame = 0x7fffdef75c90 key = {i = 0x5555561789d0 <lispsym+51184>} used_mouse_menu = false echo_local_start = 0 last_real_key_start = 0 keys_local_start = 0 new_binding = {i = 0x7fffffffd3f0} count = {bytes = 96} t = 0 echo_start = 0 keys_start = 0 current_binding = {i = 0x7fffdf1682d3} first_unbound = 31 mock_input = 0 used_mouse_menu_history = {false <repeats 30 times>} fkey = {parent = {i = 0x7fffdef7570b}, map = {i = 0x7fffdef7570b}, start = 0, end = 0} keytran = {parent = {i = 0x7fffe0ec8423}, map = {i = 0x7fffe0ec8423}, start = 0, end = 0} indec = {parent = {i = 0x7fffdef756f3}, map = {i = 0x7fffdef756f3}, start = 0, end = 0} shift_translated = false delayed_switch_frame = {i = 0x0} original_uppercase = {i = 0x0} original_uppercase_position = -1 starting_buffer = 0x7fffe08950e0 fake_prefixed_keys = {i = 0x0} first_event = {i = 0x0} second_event = {i = 0x0} #34 0x00005555557584f3 in command_loop_1 () at keyboard.c:1435 cmd = {i = 0x38} keybuf = {{i = 0x0}, {i = 0x0}, {i = 0x7fffffffd5f0}, {i = 0x55555580eaeb <set_internal+1471>}, {i = 0x200000038}, {i = 0x0}, {i = 0x0}, {i = 0xce80}, {i = 0x7fffdf166cb4}, {i = 0x7fffdec80f03}, {i = 0x7fffdec80f03}, {i = 0xce80}, {i = 0x555555ae2910 <o_fwd>}, {i = 0x7fffe08950e0}, {i = 0x0}, {i = 0x555556179060 <lispsym+52864>}, {i = 0x55555580837d <builtin_lisp_symbol+49>}, {i = 0x0}, {i = 0x7fffffffd680}, {i = 0x55555580f663 <set_default_internal+905>}, {i = 0x7fffe08950e5}, {i = 0x256207810}, {i = 0x0}, {i = 0xce80}, {i = 0x555555ae2910 <o_fwd>}, {i = 0x7fffe0699feb}, {i = 0x7fffe0c49b13}, {i = 0x0}, {i = 0x7fffffffd6c0}, {i = 0xce80}} i = 21845 last_pt = 168 prev_modiff = 0 prev_buffer = 0x0 #35 0x0000555555831291 in internal_condition_case (bfun=0x5555557580c4 <command_loop_1>, handlers=..., hfun=0x555555757542 <cmd_error>) at eval.c:1627 val = {i = 0x14e78} c = 0x7fffdec84aa0 #36 0x0000555555757c8a in command_loop_2 (handlers=...) at keyboard.c:1174 val = {i = 0x14e78} #37 0x00005555558306e8 in internal_catch (tag=..., func=0x555555757c60 <command_loop_2>, arg=...) at eval.c:1306 val = {i = 0x55555575432e <builtin_lisp_symbol+49>} c = 0x7fffdec84970 #38 0x0000555555757c1c in command_loop () at keyboard.c:1152 #39 0x0000555555756fe4 in recursive_edit_1 () at keyboard.c:760 count = {bytes = 32} val = {i = 0x7fffffffd8e0} #40 0x0000555555757210 in Frecursive_edit () at keyboard.c:843 count = {bytes = 0} buffer = {i = 0x0} #41 0x0000555555752a73 in main (argc=2, argv=0x7fffffffdb98) at emacs.c:2658 stack_bottom_variable = 0x7ffff6059094 old_argc = 2 dump_file = 0x0 no_loadup = false junk = 0x0 dname_arg = 0x0 ch_to_dir = 0x0 original_pwd = 0x0 dump_mode = 0x0 skip_args = 0 temacs = 0x0 attempt_load_pdump = true only_version = false rlim = {rlim_cur = 16777216, rlim_max = 18446744073709551615} lc_all = 0x0 sockfd = -1 module_assertions = false In GNU Emacs 31.0.50 (build 3, x86_64-pc-linux-gnu, GTK+ Version 3.24.43, cairo version 1.18.2) of 2025-01-19 built on clove Repository revision: 7c68dc80c840c4450a1bd0a2d4b2350e649ac06c Repository branch: feature/igc System Description: Debian GNU/Linux trixie/sid Configured using: 'configure --with-tree-sitter --with-pgtk --with-native-compilation --with-mps=debug LDFLAGS=-L/opt/mps/lib CPPFLAGS=-I/opt/mps/include --enable-checking=yes,glyphs --enable-check-lisp-object-type 'CFLAGS=-O0 -g3'' Configured features: CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG LCMS2 LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 MODULES MPS NATIVE_COMP NOTIFY INOTIFY PDUMPER PGTK PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XIM GTK3 ZLIB Important settings: value of $LANG: en_HK.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Fundamental Minor modes in effect: denote-rename-buffer-mode: t denote-menu-bar-mode: t pdf-occur-global-minor-mode: t which-key-mode: t sleep-wake-mode: t global-jinx-mode: t gcmh-mode: t global-flycheck-mode: t global-corfu-mode: t corfu-mode: t nerd-icons-completion-mode: t marginalia-mode: t vertico-multiform-mode: t vertico-mode: t doom-modeline-mode: t server-mode: t xterm-mouse-mode: t elpaca-use-package-mode: t override-global-mode: t windmove-mode: t pixel-scroll-precision-mode: t delete-selection-mode: t tooltip-mode: t global-eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t window-divider-mode: t minibuffer-regexp-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: /home/cohen/.emacs.d/elpaca/builds/git-commit/git-commit hides /home/cohen/.emacs.d/elpaca/builds/magit/git-commit /home/cohen/.emacs.d/elpaca/builds/which-key/which-key hides /home/cohen/src/git/emacs/lisp/which-key /home/cohen/.emacs.d/elpaca/builds/org/ox-html hides /home/cohen/src/git/emacs/lisp/org/ox-html /home/cohen/.emacs.d/elpaca/builds/org/org-mobile hides /home/cohen/src/git/emacs/lisp/org/org-mobile /home/cohen/.emacs.d/elpaca/builds/org/ox-icalendar hides /home/cohen/src/git/emacs/lisp/org/ox-icalendar /home/cohen/.emacs.d/elpaca/builds/org/org-attach-git hides /home/cohen/src/git/emacs/lisp/org/org-attach-git /home/cohen/.emacs.d/elpaca/builds/org/ol-bibtex hides /home/cohen/src/git/emacs/lisp/org/ol-bibtex /home/cohen/.emacs.d/elpaca/builds/org/ob-makefile hides /home/cohen/src/git/emacs/lisp/org/ob-makefile /home/cohen/.emacs.d/elpaca/builds/org/ob-groovy hides /home/cohen/src/git/emacs/lisp/org/ob-groovy /home/cohen/.emacs.d/elpaca/builds/org/ob-lilypond hides /home/cohen/src/git/emacs/lisp/org/ob-lilypond /home/cohen/.emacs.d/elpaca/builds/org/ob-core hides /home/cohen/src/git/emacs/lisp/org/ob-core /home/cohen/.emacs.d/elpaca/builds/org/org-tempo hides /home/cohen/src/git/emacs/lisp/org/org-tempo /home/cohen/.emacs.d/elpaca/builds/org/org-loaddefs hides /home/cohen/src/git/emacs/lisp/org/org-loaddefs /home/cohen/.emacs.d/elpaca/builds/org/ol-info hides /home/cohen/src/git/emacs/lisp/org/ol-info /home/cohen/.emacs.d/elpaca/builds/org/ob-ditaa hides /home/cohen/src/git/emacs/lisp/org/ob-ditaa /home/cohen/.emacs.d/elpaca/builds/org/oc-bibtex hides /home/cohen/src/git/emacs/lisp/org/oc-bibtex /home/cohen/.emacs.d/elpaca/builds/org/org-clock hides /home/cohen/src/git/emacs/lisp/org/org-clock /home/cohen/.emacs.d/elpaca/builds/org/oc hides /home/cohen/src/git/emacs/lisp/org/oc /home/cohen/.emacs.d/elpaca/builds/org/ob-js hides /home/cohen/src/git/emacs/lisp/org/ob-js /home/cohen/.emacs.d/elpaca/builds/org/ox-org hides /home/cohen/src/git/emacs/lisp/org/ox-org /home/cohen/.emacs.d/elpaca/builds/org/ob-latex hides /home/cohen/src/git/emacs/lisp/org/ob-latex /home/cohen/.emacs.d/elpaca/builds/org/ob-table hides /home/cohen/src/git/emacs/lisp/org/ob-table /home/cohen/.emacs.d/elpaca/builds/org/ol-doi hides /home/cohen/src/git/emacs/lisp/org/ol-doi /home/cohen/.emacs.d/elpaca/builds/org/ob-dot hides /home/cohen/src/git/emacs/lisp/org/ob-dot /home/cohen/.emacs.d/elpaca/builds/org/ob-css hides /home/cohen/src/git/emacs/lisp/org/ob-css /home/cohen/.emacs.d/elpaca/builds/org/ox hides /home/cohen/src/git/emacs/lisp/org/ox /home/cohen/.emacs.d/elpaca/builds/org/ol-mhe hides /home/cohen/src/git/emacs/lisp/org/ol-mhe /home/cohen/.emacs.d/elpaca/builds/org/ob-lua hides /home/cohen/src/git/emacs/lisp/org/ob-lua /home/cohen/.emacs.d/elpaca/builds/org/ob-python hides /home/cohen/src/git/emacs/lisp/org/ob-python /home/cohen/.emacs.d/elpaca/builds/org/oc-biblatex hides /home/cohen/src/git/emacs/lisp/org/oc-biblatex /home/cohen/.emacs.d/elpaca/builds/org/org-attach hides /home/cohen/src/git/emacs/lisp/org/org-attach /home/cohen/.emacs.d/elpaca/builds/org/ob-julia hides /home/cohen/src/git/emacs/lisp/org/ob-julia /home/cohen/.emacs.d/elpaca/builds/org/ob-sqlite hides /home/cohen/src/git/emacs/lisp/org/ob-sqlite /home/cohen/.emacs.d/elpaca/builds/org/org-plot hides /home/cohen/src/git/emacs/lisp/org/org-plot /home/cohen/.emacs.d/elpaca/builds/org/ob-R hides /home/cohen/src/git/emacs/lisp/org/ob-R /home/cohen/.emacs.d/elpaca/builds/org/ob-perl hides /home/cohen/src/git/emacs/lisp/org/ob-perl /home/cohen/.emacs.d/elpaca/builds/org/ox-latex hides /home/cohen/src/git/emacs/lisp/org/ox-latex /home/cohen/.emacs.d/elpaca/builds/org/org-list hides /home/cohen/src/git/emacs/lisp/org/org-list /home/cohen/.emacs.d/elpaca/builds/org/ob-screen hides /home/cohen/src/git/emacs/lisp/org/ob-screen /home/cohen/.emacs.d/elpaca/builds/org/org-src hides /home/cohen/src/git/emacs/lisp/org/org-src /home/cohen/.emacs.d/elpaca/builds/org/org-mouse hides /home/cohen/src/git/emacs/lisp/org/org-mouse /home/cohen/.emacs.d/elpaca/builds/org/org-ctags hides /home/cohen/src/git/emacs/lisp/org/org-ctags /home/cohen/.emacs.d/elpaca/builds/org/org-lint hides /home/cohen/src/git/emacs/lisp/org/org-lint /home/cohen/.emacs.d/elpaca/builds/org/ox-publish hides /home/cohen/src/git/emacs/lisp/org/ox-publish /home/cohen/.emacs.d/elpaca/builds/org/ob-forth hides /home/cohen/src/git/emacs/lisp/org/ob-forth /home/cohen/.emacs.d/elpaca/builds/org/org-macs hides /home/cohen/src/git/emacs/lisp/org/org-macs /home/cohen/.emacs.d/elpaca/builds/org/org-fold hides /home/cohen/src/git/emacs/lisp/org/org-fold /home/cohen/.emacs.d/elpaca/builds/org/org-element hides /home/cohen/src/git/emacs/lisp/org/org-element /home/cohen/.emacs.d/elpaca/builds/org/ol hides /home/cohen/src/git/emacs/lisp/org/ol /home/cohen/.emacs.d/elpaca/builds/org/ob-sql hides /home/cohen/src/git/emacs/lisp/org/ob-sql /home/cohen/.emacs.d/elpaca/builds/org/ob-ocaml hides /home/cohen/src/git/emacs/lisp/org/ob-ocaml /home/cohen/.emacs.d/elpaca/builds/org/ob-gnuplot hides /home/cohen/src/git/emacs/lisp/org/ob-gnuplot /home/cohen/.emacs.d/elpaca/builds/org/org-element-ast hides /home/cohen/src/git/emacs/lisp/org/org-element-ast /home/cohen/.emacs.d/elpaca/builds/org/ob-sass hides /home/cohen/src/git/emacs/lisp/org/ob-sass /home/cohen/.emacs.d/elpaca/builds/org/ob-shell hides /home/cohen/src/git/emacs/lisp/org/ob-shell /home/cohen/.emacs.d/elpaca/builds/org/org hides /home/cohen/src/git/emacs/lisp/org/org /home/cohen/.emacs.d/elpaca/builds/org/ob-clojure hides /home/cohen/src/git/emacs/lisp/org/ob-clojure /home/cohen/.emacs.d/elpaca/builds/org/org-table hides /home/cohen/src/git/emacs/lisp/org/org-table /home/cohen/.emacs.d/elpaca/builds/org/ob-awk hides /home/cohen/src/git/emacs/lisp/org/ob-awk /home/cohen/.emacs.d/elpaca/builds/org/ob-matlab hides /home/cohen/src/git/emacs/lisp/org/ob-matlab /home/cohen/.emacs.d/elpaca/builds/org/org-pcomplete hides /home/cohen/src/git/emacs/lisp/org/org-pcomplete /home/cohen/.emacs.d/elpaca/builds/org/ob-plantuml hides /home/cohen/src/git/emacs/lisp/org/ob-plantuml /home/cohen/.emacs.d/elpaca/builds/org/ob-lob hides /home/cohen/src/git/emacs/lisp/org/ob-lob /home/cohen/.emacs.d/elpaca/builds/org/ol-man hides /home/cohen/src/git/emacs/lisp/org/ol-man /home/cohen/.emacs.d/elpaca/builds/org/ob-octave hides /home/cohen/src/git/emacs/lisp/org/ob-octave /home/cohen/.emacs.d/elpaca/builds/org/ox-texinfo hides /home/cohen/src/git/emacs/lisp/org/ox-texinfo /home/cohen/.emacs.d/elpaca/builds/org/ob-tangle hides /home/cohen/src/git/emacs/lisp/org/ob-tangle /home/cohen/.emacs.d/elpaca/builds/org/ob-calc hides /home/cohen/src/git/emacs/lisp/org/ob-calc /home/cohen/.emacs.d/elpaca/builds/org/org-duration hides /home/cohen/src/git/emacs/lisp/org/org-duration /home/cohen/.emacs.d/elpaca/builds/org/org-num hides /home/cohen/src/git/emacs/lisp/org/org-num /home/cohen/.emacs.d/elpaca/builds/org/ol-eww hides /home/cohen/src/git/emacs/lisp/org/ol-eww /home/cohen/.emacs.d/elpaca/builds/org/ob-ref hides /home/cohen/src/git/emacs/lisp/org/ob-ref /home/cohen/.emacs.d/elpaca/builds/org/ob-eval hides /home/cohen/src/git/emacs/lisp/org/ob-eval /home/cohen/.emacs.d/elpaca/builds/org/ox-beamer hides /home/cohen/src/git/emacs/lisp/org/ox-beamer /home/cohen/.emacs.d/elpaca/builds/org/org-capture hides /home/cohen/src/git/emacs/lisp/org/org-capture /home/cohen/.emacs.d/elpaca/builds/org/ob-java hides /home/cohen/src/git/emacs/lisp/org/ob-java /home/cohen/.emacs.d/elpaca/builds/org/org-inlinetask hides /home/cohen/src/git/emacs/lisp/org/org-inlinetask /home/cohen/.emacs.d/elpaca/builds/org/org-id hides /home/cohen/src/git/emacs/lisp/org/org-id /home/cohen/.emacs.d/elpaca/builds/org/ob-comint hides /home/cohen/src/git/emacs/lisp/org/ob-comint /home/cohen/.emacs.d/elpaca/builds/org/ob-C hides /home/cohen/src/git/emacs/lisp/org/ob-C /home/cohen/.emacs.d/elpaca/builds/org/org-colview hides /home/cohen/src/git/emacs/lisp/org/org-colview /home/cohen/.emacs.d/elpaca/builds/org/org-datetree hides /home/cohen/src/git/emacs/lisp/org/org-datetree /home/cohen/.emacs.d/elpaca/builds/org/ox-odt hides /home/cohen/src/git/emacs/lisp/org/ox-odt /home/cohen/.emacs.d/elpaca/builds/org/ob-fortran hides /home/cohen/src/git/emacs/lisp/org/ob-fortran /home/cohen/.emacs.d/elpaca/builds/org/org-crypt hides /home/cohen/src/git/emacs/lisp/org/org-crypt /home/cohen/.emacs.d/elpaca/builds/org/org-fold-core hides /home/cohen/src/git/emacs/lisp/org/org-fold-core /home/cohen/.emacs.d/elpaca/builds/org/ol-rmail hides /home/cohen/src/git/emacs/lisp/org/ol-rmail /home/cohen/.emacs.d/elpaca/builds/org/ob-exp hides /home/cohen/src/git/emacs/lisp/org/ob-exp /home/cohen/.emacs.d/elpaca/builds/org/ob-maxima hides /home/cohen/src/git/emacs/lisp/org/ob-maxima /home/cohen/.emacs.d/elpaca/builds/org/ol-docview hides /home/cohen/src/git/emacs/lisp/org/ol-docview /home/cohen/.emacs.d/elpaca/builds/org/ox-man hides /home/cohen/src/git/emacs/lisp/org/ox-man /home/cohen/.emacs.d/elpaca/builds/org/org-entities hides /home/cohen/src/git/emacs/lisp/org/org-entities /home/cohen/.emacs.d/elpaca/builds/org/ox-ascii hides /home/cohen/src/git/emacs/lisp/org/ox-ascii /home/cohen/.emacs.d/elpaca/builds/org/ob-ruby hides /home/cohen/src/git/emacs/lisp/org/ob-ruby /home/cohen/.emacs.d/elpaca/builds/org/ox-md hides /home/cohen/src/git/emacs/lisp/org/ox-md /home/cohen/.emacs.d/elpaca/builds/org/org-faces hides /home/cohen/src/git/emacs/lisp/org/org-faces /home/cohen/.emacs.d/elpaca/builds/org/ol-bbdb hides /home/cohen/src/git/emacs/lisp/org/ol-bbdb /home/cohen/.emacs.d/elpaca/builds/org/org-agenda hides /home/cohen/src/git/emacs/lisp/org/org-agenda /home/cohen/.emacs.d/elpaca/builds/org/org-keys hides /home/cohen/src/git/emacs/lisp/org/org-keys /home/cohen/.emacs.d/elpaca/builds/org/ol-w3m hides /home/cohen/src/git/emacs/lisp/org/ol-w3m /home/cohen/.emacs.d/elpaca/builds/org/ob-sed hides /home/cohen/src/git/emacs/lisp/org/ob-sed /home/cohen/.emacs.d/elpaca/builds/org/org-version hides /home/cohen/src/git/emacs/lisp/org/org-version /home/cohen/.emacs.d/elpaca/builds/org/ol-eshell hides /home/cohen/src/git/emacs/lisp/org/ol-eshell /home/cohen/.emacs.d/elpaca/builds/org/org-archive hides /home/cohen/src/git/emacs/lisp/org/org-archive /home/cohen/.emacs.d/elpaca/builds/org/ob-emacs-lisp hides /home/cohen/src/git/emacs/lisp/org/ob-emacs-lisp /home/cohen/.emacs.d/elpaca/builds/org/org-macro hides /home/cohen/src/git/emacs/lisp/org/org-macro /home/cohen/.emacs.d/elpaca/builds/org/ob hides /home/cohen/src/git/emacs/lisp/org/ob /home/cohen/.emacs.d/elpaca/builds/org/org-cycle hides /home/cohen/src/git/emacs/lisp/org/org-cycle /home/cohen/.emacs.d/elpaca/builds/org/org-persist hides /home/cohen/src/git/emacs/lisp/org/org-persist /home/cohen/.emacs.d/elpaca/builds/org/ob-processing hides /home/cohen/src/git/emacs/lisp/org/ob-processing /home/cohen/.emacs.d/elpaca/builds/org/org-refile hides /home/cohen/src/git/emacs/lisp/org/org-refile /home/cohen/.emacs.d/elpaca/builds/org/oc-basic hides /home/cohen/src/git/emacs/lisp/org/oc-basic /home/cohen/.emacs.d/elpaca/builds/org/ob-org hides /home/cohen/src/git/emacs/lisp/org/ob-org /home/cohen/.emacs.d/elpaca/builds/org/org-indent hides /home/cohen/src/git/emacs/lisp/org/org-indent /home/cohen/.emacs.d/elpaca/builds/org/ob-eshell hides /home/cohen/src/git/emacs/lisp/org/ob-eshell /home/cohen/.emacs.d/elpaca/builds/org/org-goto hides /home/cohen/src/git/emacs/lisp/org/org-goto /home/cohen/.emacs.d/elpaca/builds/org/oc-natbib hides /home/cohen/src/git/emacs/lisp/org/oc-natbib /home/cohen/.emacs.d/elpaca/builds/org/org-protocol hides /home/cohen/src/git/emacs/lisp/org/org-protocol /home/cohen/.emacs.d/elpaca/builds/org/org-habit hides /home/cohen/src/git/emacs/lisp/org/org-habit /home/cohen/.emacs.d/elpaca/builds/org/org-footnote hides /home/cohen/src/git/emacs/lisp/org/org-footnote /home/cohen/.emacs.d/elpaca/builds/org/ol-gnus hides /home/cohen/src/git/emacs/lisp/org/ol-gnus /home/cohen/.emacs.d/elpaca/builds/org/ob-haskell hides /home/cohen/src/git/emacs/lisp/org/ob-haskell /home/cohen/.emacs.d/elpaca/builds/org/org-feed hides /home/cohen/src/git/emacs/lisp/org/org-feed /home/cohen/.emacs.d/elpaca/builds/org/ob-lisp hides /home/cohen/src/git/emacs/lisp/org/ob-lisp /home/cohen/.emacs.d/elpaca/builds/org/org-timer hides /home/cohen/src/git/emacs/lisp/org/org-timer /home/cohen/.emacs.d/elpaca/builds/org/oc-csl hides /home/cohen/src/git/emacs/lisp/org/oc-csl /home/cohen/.emacs.d/elpaca/builds/org/ob-scheme hides /home/cohen/src/git/emacs/lisp/org/ob-scheme /home/cohen/.emacs.d/elpaca/builds/org/ox-koma-letter hides /home/cohen/src/git/emacs/lisp/org/ox-koma-letter /home/cohen/.emacs.d/elpaca/builds/org/ol-irc hides /home/cohen/src/git/emacs/lisp/org/ol-irc /home/cohen/.emacs.d/elpaca/builds/org/org-compat hides /home/cohen/src/git/emacs/lisp/org/org-compat Features: (shadow emacsbug nerd-icons-dired dired-quick-sort hydra savehist ls-lisp denote-rename-buffer denote gnus-dired smerge-mode diff bbdb-gnus macros url-queue flow-fill tetris gamegrid org-bullets toc-org org-indent oc-basic ol-gnus ol-info ol-docview doc-view ol-bibtex bibtex ol-bbdb pdf-sync pdf-annot pdf-outline pdf-links pdf-history pdf-occur ibuf-ext ibuffer ibuffer-loaddefs tablist advice tablist-filter semantic/wisent/comp semantic/wisent semantic/wisent/wisent semantic/util-modes semantic/util semantic semantic/tag semantic/lex semantic/fw mode-local cedet pdf-isearch let-alist pdf-misc pdf-tools package url-handlers pdf-view pdf-cache pdf-info tq pdf-util pdf-macs bbdb-message mailalias bbdb-mua bbdb-com crm bbdb bbdb-site timezone shr-color helpful cc-langs cc-vars cc-defs trace cl-print edebug debug backtrace elisp-refs image-mode exif dired-aux enriched facemenu jka-compr mm-archive misearch multi-isearch vc-git diff-mode track-changes vc-dispatcher bug-reference vertico-indexed gnus-gravatar gravatar dns sort smiley gnus-cite mail-extr textsec uni-scripts idna-mapping ucs-normalize uni-confusable textsec-check gnus-bcklg gnus-async gnus-kill gnus-dup qp gnus-ml disp-table hl-line gnus-topic gnus-search eieio-opt speedbar ezimage dframe nndraft nnmh url-cache utf-7 nnml nnfolder epa-file gnus-agent gnus-srvr gnus-score score-mode nnvirtual gnus-msg gnus-cache dot-gnus gnus-demon nntp gnus-icalendar org-protocol-capture-html org-protocol org-capture org-tufte ox-odt rng-loc rng-uri rng-parse rng-match rng-dt rng-util rng-pttrn nxml-parse nxml-ns nxml-enc xmltok nxml-util ox-latex ox-icalendar org-agenda ox-html table ox-ascii ox-publish ox org-attach org-element org-persist org-id org-refile org-element-ast avl-tree org ob ob-tangle ob-ref ob-lob ob-table ob-exp org-macro org-src sh-script smie executable ob-comint org-pcomplete org-list org-footnote org-faces org-entities ob-emacs-lisp ob-core ob-eval org-cycle org-table ol org-fold org-fold-core org-keys oc org-version org-compat org-macs icalendar diary-lib diary-loaddefs cal-china-x cal-china lunar solar cal-dst holidays holiday-loaddefs cal-menu calendar cal-loaddefs gnus-todo nnselect gnus-art mm-uu mml2015 mm-view mml-smime smime gnutls dig gnus-sum shr pixel-fill kinsoku url-file svg dom gnus-group gnus-undo gnus-start gnus-cloud nnimap nnmail mail-source utf7 nnoo gnus-spec gnus-int gnus-range company-bbdb message sendmail yank-media dired dired-loaddefs rfc822 mml mml-sec epa derived mm-decode mm-bodies mm-encode mailabbrev gmm-utils mailheader gnus-win gnus nnheader gnus-util mail-utils range help-fns radix-tree which-key gnuplot info-look info face-remap hi-lock tramp-cmds tramp-cache time-stamp tramp-sh tramp trampver tramp-integration tramp-message tramp-compat shell parse-time iso8601 time-date format-spec tramp-loaddefs sleep dbus xml lightway-vpn vertico-directory mule-util vertico-reverse pulse jinx treesit-auto treesit gcmh lsp-latex lsp-mode lsp-protocol xref project tree-widget spinner network-stream markdown-mode color thingatpt noutline outline lv inline imenu ht filenotify ewoc compile flycheck find-func oauth2 url-http url-auth mail-parse rfc2231 rfc2047 rfc2045 mm-util ietf-drums mail-prsvr url-gw nsm puny plstore epg rfc6068 epg-config cape nerd-icons-corfu corfu nerd-icons-completion marginalia consult bookmark text-property-search cus-start orderless edmacro kmacro vertico-multiform vertico doom-modeline doom-modeline-segments doom-modeline-env doom-modeline-core comp comp-cstr warnings comp-run comp-common shrink-path rx f s dash compat nerd-icons nerd-icons-faces nerd-icons-data nerd-icons-data-mdicon nerd-icons-data-flicon nerd-icons-data-codicon nerd-icons-data-devicon nerd-icons-data-sucicon nerd-icons-data-wicon nerd-icons-data-faicon nerd-icons-data-powerline nerd-icons-data-octicon nerd-icons-data-pomicon nerd-icons-data-ipsicon org-node-autoloads el-job-autoloads llama-autoloads denote-autoloads go-translate-autoloads treesit-auto-autoloads webkit-autoloads gcmh-autoloads lsp-latex-autoloads consult-lsp-autoloads dap-mode-autoloads bui-autoloads lsp-docker-autoloads yaml-autoloads lsp-treemacs-autoloads treemacs-autoloads ace-window-autoloads avy-autoloads pfuture-autoloads cfrs-autoloads posframe-autoloads lsp-ui-autoloads lsp-mode-autoloads ht-autoloads spinner-autoloads markdown-mode-autoloads consult-flycheck-autoloads flycheck-pos-tip-autoloads pos-tip-autoloads flycheck-autoloads dired-quick-sort-autoloads hydra-autoloads lv-autoloads git-commit-autoloads magit-autoloads magit-section-autoloads with-editor-autoloads oauth2-autoloads cal-china-x-autoloads bbdb-autoloads gnuplot-autoloads jinx-autoloads pdf-tools-autoloads tablist-autoloads org-bullets-autoloads toc-org-autoloads org-loaddefs yasnippet-snippets-autoloads yasnippet-autoloads cape-autoloads corfu-autoloads which-key-autoloads helpful-autoloads elisp-refs-autoloads embark-consult-autoloads embark-autoloads marginalia-autoloads consult-autoloads orderless-autoloads vertico-autoloads doom-modeline-autoloads shrink-path-autoloads f-autoloads s-autoloads dash-autoloads nerd-icons-completion-autoloads nerd-icons-corfu-autoloads nerd-icons-dired-autoloads nerd-icons-autoloads init cohen_elpaca server eudcb-ldap ldap eudc eudc-vars pcase xt-mouse avoid cl-extra help-mode poet-theme elpaca-use-package use-package use-package-ensure use-package-delight use-package-diminish use-package-bind-key bind-key easy-mmode use-package-core elpaca-use-package-autoloads elpaca-log elpaca-ui windmove pixel-scroll cua-base em-smart esh-mode esh-var eshell esh-cmd generator esh-ext esh-proc esh-opt esh-io esh-arg pcomplete comint ansi-osc ansi-color ring esh-module esh-module-loaddefs esh-util files-x ps-bdf ps-mule ps-print ps-print-loaddefs lpr browse-url xdg delsel cus-edit pp cus-load wid-edit elpaca-menu-elpa elpaca-menu-melpa url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util url-parse auth-source cl-seq eieio eieio-core cl-macs icons password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars mailcap elpaca-menu-org elpaca elpaca-process cl-loaddefs cl-lib elpaca-autoloads early-init rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/pgtk-win pgtk-win term/common-win touch-screen pgtk-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify dynamic-setting system-font-setting font-render-setting cairo gtk pgtk lcms2 multi-tty move-toolbar make-network-process tty-child-frames native-compile mps emacs) Memory information: ((conses 24 0 0) (symbols 56 0 0) (strings 40 0 0) (string-bytes 1 0) (vectors 24 0) (vector-slots 8 0 0) (floats 24 0 0) (intervals 64 0 0) (buffers 1000 0)) -- Andrew Cohen
bug-gnu-emacs <at> gnu.org
:bug#75905
; Package emacs
.
(Tue, 28 Jan 2025 13:01:02 GMT) Full text and rfc822 format available.Message #8 received at 75905 <at> debbugs.gnu.org (full text, mbox):
From: Eli Zaretskii <eliz <at> gnu.org> To: Andrew Cohen <acohen <at> ust.hk> Cc: 75905 <at> debbugs.gnu.org Subject: Re: bug#75905: 31.0.50; feature/igc: crash when clicking menubar Date: Tue, 28 Jan 2025 15:00:18 +0200
> From: Andrew Cohen <acohen <at> ust.hk> > Date: Tue, 28 Jan 2025 15:02:54 +0800 > > pgtk emacs with mpc crashes whenever the menubar is clicked. Same > configuration without igc has no problem. > > Thread 1 "emacs" received signal SIGABRT, Aborted. > __pthread_kill_implementation (threadid=<optimized out>, signo=signo <at> entry=6, > no_tid=no_tid <at> entry=0) at ./nptl/pthread_kill.c:44 > warning: 44 ./nptl/pthread_kill.c: No such file or directory > (gdb) bt full > #0 __pthread_kill_implementation > (threadid=<optimized out>, signo=signo <at> entry=6, no_tid=no_tid <at> entry=0) > at ./nptl/pthread_kill.c:44 > tid = <optimized out> > ret = 0 > pd = <optimized out> > old_mask = {__val = {140737488338656}} > ret = <optimized out> > #1 0x00007ffff1f1ddef in __pthread_kill_internal (threadid=<optimized out>, signo=6) > at ./nptl/pthread_kill.c:78 > #2 0x00007ffff1ec9d02 in __GI_raise (sig=6) at ../sysdeps/posix/raise.c:26 > ret = <optimized out> > #3 0x000055555574f608 in terminate_due_to_signal (sig=6, backtrace_limit=2147483647) > at emacs.c:470 > #4 0x00005555557f8d86 in die > (msg=0x555555a3a7c0 "((((struct vectorlike_header *) ((uintptr_t) ((void *) (globals.f_Vmenu_updating_frame).i) - (uintptr_t) ((Lisp_Word_tag) (Lisp_Vectorlike) << (1 ? 0 : VALBITS)))) ->size) & (PSEUDOVECTOR_FLAG | PVEC_"..., file=0x555555a3a76a "pgtkmenu.c", line=252) at alloc.c:8388 > #5 0x0000555555972366 in set_frame_menubar (f=0x5555565996b0, deep_p=true) at pgtkmenu.c:252 This is here: void set_frame_menubar (struct frame *f, bool deep_p) { GtkWidget *menubar_widget; Lisp_Object items; widget_value *wv, *first_wv, *prev_wv = 0; int i; int *submenu_start, *submenu_end; bool *submenu_top_level_items; int *submenu_n_panes; menubar_widget = f->output_data.pgtk->menubar_widget; XSETFRAME (Vmenu_updating_frame, f); <<<<<<<<<<<<<<<<<<<<<< Is this because vectorlike_header is a struct, not a union on the igc branch? Andrew, do other mouse clicks cause crashes like this one, in XSETFRAME?
bug-gnu-emacs <at> gnu.org
:bug#75905
; Package emacs
.
(Tue, 28 Jan 2025 19:39:02 GMT) Full text and rfc822 format available.Message #11 received at 75905 <at> debbugs.gnu.org (full text, mbox):
From: Pip Cet <pipcet <at> protonmail.com> To: Andrew Cohen <acohen <at> ust.hk> Cc: 75905 <at> debbugs.gnu.org Subject: Re: bug#75905: 31.0.50; feature/igc: crash when clicking menubar Date: Tue, 28 Jan 2025 19:38:04 +0000
"Andrew Cohen" <acohen <at> ust.hk> writes: Hi! Thanks for the report! > pgtk emacs with mpc crashes whenever the menubar is clicked. Same > configuration without igc has no problem. That makes sense. I'd just fixed this bug in the X case (the X case is slightly different: when you click a popup menu, you'll always get nil, the "no" answer in y-or-no-p, right now), but there seem to be a few more places that need it. (Note that the glib_user_data thing isn't working as well as it should, and I'm working on an improved version. The current code should be usable on plain GTK and may be usable on PGTK, but if you use menu bars and many frames things may be slow). Can you please try this patch? From: Pip Cet <pipcet <at> protonmail.com> Subject: [PATCH] [MPS] Use glib_user_data more consistently (bug#75905) * src/gtkutil.c (style_changed_cb): (xg_dialog_response_cb): (xg_toggle_notify_cb): (xg_finish_scroll_bar_creation): (menu_bar_button_pressed_cb): (find_scrollbar_cb): (create_menus): (xg_create_frame_widgets): (xg_create_frame_outer_widgets): (xg_tool_bar_callback): (xg_tool_bar_help_callback): (xg_make_tool_item): (xg_dialog_run): (xg_get_file_with_chooser): (xg_get_widget_from_map): Use glib_user_data, free_glib_user_data. * src/pgtkmenu.c (menubar_selection_callback): (popup_selection_callback): Use glib_user_data, get_glib_user_data. --- src/gtkutil.c | 92 ++++++++++++++++++++++++++++---------------------- src/pgtkmenu.c | 4 +-- 2 files changed, 54 insertions(+), 42 deletions(-) diff --git a/src/gtkutil.c b/src/gtkutil.c index 09ba18e1526..2bb2735105c 100644 --- a/src/gtkutil.c +++ b/src/gtkutil.c @@ -1474,7 +1474,7 @@ style_changed_cb (GObject *go, gpointer user_data) { struct input_event event; - GdkDisplay *gdpy = user_data; + GdkDisplay *gdpy = get_glib_user_data (user_data); const char *display_name = gdk_display_get_name (gdpy); #ifndef HAVE_PGTK Display *dpy = GDK_DISPLAY_XDISPLAY (gdpy); @@ -1788,9 +1788,10 @@ xg_create_frame_widgets (struct frame *f) (gpointer) G_CALLBACK (style_changed_cb), 0)) { - g_signal_connect (G_OBJECT (gs), "notify::gtk-theme-name", - G_CALLBACK (style_changed_cb), - gdk_screen_get_display (screen)); + g_signal_connect_data (G_OBJECT (gs), "notify::gtk-theme-name", + G_CALLBACK (style_changed_cb), + glib_user_data (gdk_screen_get_display (screen)), + free_glib_user_data, 0); } } @@ -1893,9 +1894,10 @@ xg_create_frame_outer_widgets (struct frame *f) (gpointer) G_CALLBACK (style_changed_cb), 0)) { - g_signal_connect (G_OBJECT (gs), "notify::gtk-theme-name", - G_CALLBACK (style_changed_cb), - gdk_screen_get_display (screen)); + g_signal_connect_data (G_OBJECT (gs), "notify::gtk-theme-name", + G_CALLBACK (style_changed_cb), + glib_user_data (gdk_screen_get_display (screen)), + free_glib_user_data, 0); } } @@ -2442,7 +2444,7 @@ xg_dialog_response_cb (GtkDialog *w, gint response, gpointer user_data) { - struct xg_dialog_data *dd = user_data; + struct xg_dialog_data *dd = get_glib_user_data (user_data); dd->response = response; g_main_loop_quit (dd->loop); } @@ -2509,10 +2511,11 @@ xg_dialog_run (struct frame *f, GtkWidget *w) dd.w = w; dd.timerid = 0; - g_signal_connect (G_OBJECT (w), - "response", - G_CALLBACK (xg_dialog_response_cb), - &dd); + g_signal_connect_data (G_OBJECT (w), + "response", + G_CALLBACK (xg_dialog_response_cb), + glib_user_data (&dd), free_glib_user_data, + 0); /* Don't destroy the widget if closed by the window manager close button. */ g_signal_connect (G_OBJECT (w), "delete-event", G_CALLBACK (gtk_true), NULL); gtk_widget_show (w); @@ -2580,7 +2583,7 @@ xg_toggle_notify_cb (GObject *gobject, GParamSpec *arg1, gpointer user_data) { if (strcmp (arg1->name, "show-hidden") == 0) { - GtkWidget *wtoggle = GTK_WIDGET (user_data); + GtkWidget *wtoggle = GTK_WIDGET (get_glib_user_data (user_data)); gboolean visible, toggle_on; g_object_get (G_OBJECT (gobject), "show-hidden", &visible, NULL); @@ -2646,10 +2649,13 @@ xg_get_file_with_chooser (struct frame *f, x_gtk_show_hidden_files); gtk_widget_show (wtoggle); - g_signal_connect (G_OBJECT (wtoggle), "clicked", - G_CALLBACK (xg_toggle_visibility_cb), filewin); - g_signal_connect (G_OBJECT (filewin), "notify", - G_CALLBACK (xg_toggle_notify_cb), wtoggle); + g_signal_connect_data (G_OBJECT (wtoggle), "clicked", + G_CALLBACK (xg_toggle_visibility_cb), + glib_user_data (filewin), + free_glib_user_data, 0); + g_signal_connect_data (G_OBJECT (filewin), "notify", + G_CALLBACK (xg_toggle_notify_cb), glib_user_data (wtoggle), + free_glib_user_data, 0); if (x_gtk_file_dialog_help_text) { @@ -3362,7 +3368,7 @@ xg_create_one_menuitem (widget_value *item, menu_bar_button_pressed_cb (GtkWidget *widget, GdkEvent *event, gpointer user_data) { - struct frame *f = user_data; + struct frame *f = get_glib_user_data (user_data); if (event->button.button < 4 && event->button.window != gtk_widget_get_window (widget) @@ -3440,9 +3446,9 @@ create_menus (widget_value *data, #ifdef HAVE_PGTK g_signal_connect_data (G_OBJECT (wmenu), "button-press-event", - G_CALLBACK (menu_bar_button_pressed_cb), - glib_user_data (f), free_glib_user_data, - 0); + G_CALLBACK (menu_bar_button_pressed_cb), + glib_user_data (f), free_glib_user_data, + 0); #endif /* Set width of menu bar to a small value so it doesn't enlarge a small initial frame size. The width will be set to the @@ -4443,7 +4449,7 @@ xg_get_widget_from_map (ptrdiff_t idx, Display *dpy) static void find_scrollbar_cb (GtkWidget *widget, gpointer user_data) { - GtkWidget **scroll_bar = user_data; + GtkWidget **scroll_bar = get_glib_user_data (user_data); if (GTK_IS_SCROLLBAR (widget)) *scroll_bar = widget; @@ -4464,9 +4470,11 @@ xg_get_widget_from_map (ptrdiff_t window, Display *dpy) event.any.type = GDK_NOTHING; gwdesc = gtk_get_event_widget (&event); + gpointer user_data = glib_user_data (&scroll_bar); if (gwdesc && GTK_IS_EVENT_BOX (gwdesc)) gtk_container_forall (GTK_CONTAINER (gwdesc), - find_scrollbar_cb, &scroll_bar); + find_scrollbar_cb, user_data); + free_glib_user_data (user_data, NULL); } else return NULL; @@ -4634,10 +4642,11 @@ xg_finish_scroll_bar_creation (struct frame *f, #if defined HAVE_PGTK || !defined HAVE_GTK3 ptrdiff_t scroll_id = xg_store_widget_in_map (wscroll); - g_signal_connect (G_OBJECT (wscroll), - "destroy", - G_CALLBACK (xg_gtk_scroll_destroy), - (gpointer) scroll_id); + g_signal_connect_data (G_OBJECT (wscroll), + "destroy", + G_CALLBACK (xg_gtk_scroll_destroy), + glib_user_data ((gpointer) scroll_id), + free_glib_user_data, 0); #endif #ifdef HAVE_MPS @@ -5382,7 +5391,7 @@ xg_tool_bar_button_cb (GtkWidget *widget, static void xg_tool_bar_callback (GtkWidget *w, gpointer client_data) { - intptr_t idx = (intptr_t) client_data; + intptr_t idx = (intptr_t) get_glib_user_data (client_data); gpointer gmod = g_object_get_data (G_OBJECT (w), XG_TOOL_BAR_LAST_MODIFIER); intptr_t mod = (intptr_t) gmod; @@ -5444,7 +5453,7 @@ xg_tool_bar_help_callback (GtkWidget *w, GdkEventCrossing *event, gpointer client_data) { - intptr_t idx = (intptr_t) client_data; + intptr_t idx = (intptr_t) get_glib_user_data (client_data); struct frame *f = g_object_get_data (G_OBJECT (w), XG_FRAME_DATA); Lisp_Object help, frame; @@ -5692,9 +5701,10 @@ xg_make_tool_item (struct frame *f, intptr_t ii = i; gpointer gi = (gpointer) ii; - g_signal_connect (G_OBJECT (wb), "clicked", - G_CALLBACK (xg_tool_bar_callback), - gi); + g_signal_connect_data (G_OBJECT (wb), "clicked", + G_CALLBACK (xg_tool_bar_callback), + glib_user_data (gi), free_glib_user_data, + 0); g_object_set_data (G_OBJECT (weventbox), XG_FRAME_DATA, (gpointer)f); @@ -5721,14 +5731,16 @@ xg_make_tool_item (struct frame *f, rather than the GtkButton specific signals "enter" and "leave", so we can have only one callback. The event will tell us what kind of event it is. */ - g_signal_connect (G_OBJECT (weventbox), - "enter-notify-event", - G_CALLBACK (xg_tool_bar_help_callback), - gi); - g_signal_connect (G_OBJECT (weventbox), - "leave-notify-event", - G_CALLBACK (xg_tool_bar_help_callback), - gi); + g_signal_connect_data (G_OBJECT (weventbox), + "enter-notify-event", + G_CALLBACK (xg_tool_bar_help_callback), + glib_user_data (gi), free_glib_user_data, + 0); + g_signal_connect_data (G_OBJECT (weventbox), + "leave-notify-event", + G_CALLBACK (xg_tool_bar_help_callback), + glib_user_data (gi), free_glib_user_data, + 0); } if (wbutton) *wbutton = wb; diff --git a/src/pgtkmenu.c b/src/pgtkmenu.c index a2e09b6cb58..f25425435da 100644 --- a/src/pgtkmenu.c +++ b/src/pgtkmenu.c @@ -188,7 +188,7 @@ menu_highlight_callback (GtkWidget *widget, gpointer call_data) static void menubar_selection_callback (GtkWidget *widget, gpointer client_data) { - xg_menu_item_cb_data *cb_data = client_data; + xg_menu_item_cb_data *cb_data = get_glib_user_data (client_data); if (xg_crazy_callback_abort) return; @@ -510,7 +510,7 @@ initialize_frame_menubar (struct frame *f) static void popup_selection_callback (GtkWidget *widget, gpointer client_data) { - xg_menu_item_cb_data *cb_data = client_data; + xg_menu_item_cb_data *cb_data = get_glib_user_data (client_data); if (xg_crazy_callback_abort) return; -- 2.47.1 Thanks! Pip
bug-gnu-emacs <at> gnu.org
:bug#75905
; Package emacs
.
(Wed, 29 Jan 2025 02:21:02 GMT) Full text and rfc822 format available.Message #14 received at 75905 <at> debbugs.gnu.org (full text, mbox):
From: Andrew Cohen <acohen <at> ust.hk> To: Pip Cet <pipcet <at> protonmail.com> Cc: 75905 <at> debbugs.gnu.org Subject: Re: bug#75905: 31.0.50; feature/igc: crash when clicking menubar Date: Wed, 29 Jan 2025 10:19:50 +0800
>>>>> "PC" == Pip Cet <pipcet <at> protonmail.com> writes: PC> "Andrew Cohen" <acohen <at> ust.hk> writes: Hi! PC> Thanks for the report! >> pgtk emacs with mpc crashes whenever the menubar is clicked. Same >> configuration without igc has no problem. PC> That makes sense. I'd just fixed this bug in the X case (the X PC> case is slightly different: when you click a popup menu, you'll PC> always get nil, the "no" answer in y-or-no-p, right now), but PC> there seem to be a few more places that need it. PC> (Note that the glib_user_data thing isn't working as well as it PC> should, and I'm working on an improved version. The current PC> code should be usable on plain GTK and may be usable on PGTK, PC> but if you use menu bars and many frames things may be slow). PC> Can you please try this patch? Sure! And indeed, with that patch the crash is gone. Best, Andy -- Andrew Cohen
Pip Cet <pipcet <at> protonmail.com>
:Andrew Cohen <acohen <at> ust.hk>
:Message #19 received at 75905-done <at> debbugs.gnu.org (full text, mbox):
From: Pip Cet <pipcet <at> protonmail.com> To: Andrew Cohen <acohen <at> ust.hk> Cc: 75905-done <at> debbugs.gnu.org Subject: Re: bug#75905: 31.0.50; feature/igc: crash when clicking menubar Date: Sat, 01 Feb 2025 23:40:05 +0000
"Andrew Cohen" <acohen <at> ust.hk> writes: >>>>>> "PC" == Pip Cet <pipcet <at> protonmail.com> writes: > > PC> "Andrew Cohen" <acohen <at> ust.hk> writes: Hi! > > PC> Thanks for the report! > > >> pgtk emacs with mpc crashes whenever the menubar is clicked. Same > >> configuration without igc has no problem. > > PC> That makes sense. I'd just fixed this bug in the X case (the X > PC> case is slightly different: when you click a popup menu, you'll > PC> always get nil, the "no" answer in y-or-no-p, right now), but > PC> there seem to be a few more places that need it. > > PC> (Note that the glib_user_data thing isn't working as well as it > PC> should, and I'm working on an improved version. The current > PC> code should be usable on plain GTK and may be usable on PGTK, > PC> but if you use menu bars and many frames things may be slow). > > PC> Can you please try this patch? > > Sure! And indeed, with that patch the crash is gone. Thanks. Pushed, and closing. Please reopen or open new bugs as appropriate! Pip
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.