* bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated.
@ 2024-12-26 15:26 Madhu
2024-12-28 12:10 ` Eli Zaretskii
0 siblings, 1 reply; 8+ messages in thread
From: Madhu @ 2024-12-26 15:26 UTC (permalink / raw)
To: 75120
Hello, Having heard about which-key mode I decided to try it.
gdb --args ../build-xt-native/src/emacs -Q -eval '(which-key-mode 1)' -eval '(setq window-min-height 8)'
1. type C-x, wait 5 seconds, type C-g.
2. type C-x, wait 2 seconds for the 8 line frame with scrollbar, click the "up
arrow" on the top of the scrollbar.
BEGIN BACKTRACE
read 1 "emacs" received signal SIGSEGV, Segmentation fault.
0x000000000054446b in xt_action_hook (widget=<optimized out>, client_data=<optim
ized out>, action_name=0xe964d3 "EndScroll", event=<optimized out>, params=<opti
mized out>, num_params=<optimized out>) at ../../src/xterm.c:15479
15479 if (bar->dragging != -1)
(gdb) xbacktrace
(gdb) bt full
#0 0x000000000054446b in xt_action_hook (widget=<optimized out>,
client_data=<optimized out>, action_name=0xe964d3 "EndScroll",
event=<optimized out>, params=<optimized out>, num_params=<optimized out>)
at ../../src/xterm.c:15479
w = 0x1555470
bar = <optimized out>
scroll_bar_p = <optimized out>
end_action = <optimized out>
scroll_bar_p = <optimized out>
end_action = <optimized out>
w = <optimized out>
bar = <optimized out>
#1 xt_action_hook (widget=<optimized out>, client_data=<optimized out>,
action_name=0xe964d3 "EndScroll", event=<optimized out>,
params=<optimized out>, num_params=<optimized out>)
at ../../src/xterm.c:15453
scroll_bar_p = <optimized out>
end_action = 0x6f4dcb "EndScroll"
w = <optimized out>
bar = <optimized out>
#2 0x00007ffff7d0a43d in ?? () from /usr/lib64/libXt.so.6
No symbol table info available.
#3 0x0000000000e7ec10 in ?? ()
[...]
(gdb) sharedlibrary .
(gdb) back
#0 0x000000000054446b in xt_action_hook
(widget=<optimized out>, client_data=<optimized out>, action_name=0xe964d3 "EndScroll", event=<optimized out>, params=<optimized out>, num_params=<optimized out>) at ../../src/xterm.c:15479
#1 xt_action_hook
(widget=<optimized out>, client_data=<optimized out>, action_name=0xe964d3 "EndScroll", event=<optimized out>, params=<optimized out>, num_params=<optimized out>) at ../../src/xterm.c:15453
#2 0x00007ffff7d0a43d in HandleActions
(w=w@entry=0x1256750, event=0x7fffffffc5a0, stateTree=0x124a3f0, accelWidget=<optimized out>, procs=0xde6318, actions=actions@entry=0x7ffff7d2a120 <dummyAction.3>) at /usr/src/debug/x11-libs/libXt-1.3.0/libXt-1.3.0/src/TMstate.c:633
#3 0x00007ffff7d0ac91 in HandleSimpleState
(w=w@entry=0x1256750, tmRecPtr=tmRecPtr@entry=0x1256798, curEventPtr=curEventPtr@entry=0x7fffffffbdd0)
at /usr/src/debug/x11-libs/libXt-1.3.0/libXt-1.3.0/src/TMstate.c:866
#4 0x00007ffff7d0bb68 in _XtTranslateEvent
(w=w@entry=0x1256750, event=event@entry=0x7fffffffc5a0)
at /usr/src/debug/x11-libs/libXt-1.3.0/libXt-1.3.0/src/TMstate.c:1064
#5 0x00007ffff7ce4eeb in XtDispatchEventToWidget
(widget=widget@entry=0x1256750, event=event@entry=0x7fffffffc5a0)
at /usr/src/debug/x11-libs/libXt-1.3.0/libXt-1.3.0/src/Event.c:933
#6 0x00007ffff7ce55a2 in _XtDefaultDispatcher (event=0x7fffffffc5a0)
at /usr/src/debug/x11-libs/libXt-1.3.0/libXt-1.3.0/src/Event.c:1407
--Type <RET> for more, q to quit, c to continue without paging--c
#7 0x00007ffff7ce5701 in XtDispatchEvent (event=event@entry=0x7fffffffc5a0) at /usr/src/debug/x11-libs/libXt-1.3.0/libXt-1.3.0/src/Event.c:1481
#8 0x000000000055b181 in handle_one_xevent (dpyinfo=<optimized out>, event=<optimized out>, finish=<optimized out>, hold_quit=<optimized out>) at ../../src/xterm.c:25578
#9 0x0000000000566d91 in XTread_socket (terminal=<optimized out>, hold_quit=0x7fffffffc690) at ../../src/xterm.c:25740
#10 0x0000000000592341 in gobble_input () at ../../src/keyboard.c:7923
#11 0x0000000000595355 in handle_async_input () at ../../src/keyboard.c:8162
#12 process_pending_signals () at ../../src/keyboard.c:8176
#13 unblock_input_to (level=0) at ../../src/keyboard.c:8191
#14 unblock_input_to (level=<optimized out>) at ../../src/keyboard.c:8185
#15 unblock_input () at ../../src/keyboard.c:8210
#16 0x00000000006cc9d9 in xg_select (fds_lim=<optimized out>, rfds=rfds@entry=0x7fffffffcef0, wfds=<optimized out>, efds=0x0, timeout=<optimized out>, sigmask=<optimized out>) at ../../src/xgselect.c:298
#17 0x0000000000673c96 in wait_reading_process_output (time_limit=time_limit@entry=30, nsecs=nsecs@entry=0, read_kbd=read_kbd@entry=-1, do_display=do_display@entry=true, wait_for_cell=wait_for_cell@entry=XIL(0), wait_proc=wait_proc@entry=0x0, just_wait_proc=0) at ../../src/process.c:5765
#18 0x00000000004759f0 in sit_for (timeout=timeout@entry=make_fixnum(30), reading=reading@entry=true, display_option=display_option@entry=1) at ../../src/dispnew.c:6335
#19 0x000000000059a4e8 in read_char (commandflag=1, map=XIL(0x151af43), prev_event=XIL(0), used_mouse_menu=0x7fffffffd70b, end_time=0x0) at ../../src/keyboard.c:2926
#20 0x000000000059b7ef in read_key_sequence (keybuf=<optimized out>, prompt=XIL(0), dont_downcase_last=false, can_return_switch_frame=true, fix_current_buffer=true, prevent_redisplay=false, disable_text_conversion_p=false) at ../../src/keyboard.c:10747
#21 0x000000000059d446 in command_loop_1 () at ../../src/keyboard.c:1424
#22 0x0000000000613d47 in internal_condition_case (bfun=bfun@entry=0x59d2a0 <command_loop_1>, handlers=handlers@entry=XIL(0x90), hfun=hfun@entry=0x591030 <cmd_error>) at ../../src/eval.c:1607
#23 0x00000000005891ca in command_loop_2 (handlers=handlers@entry=XIL(0x90)) at ../../src/keyboard.c:1163
#24 0x0000000000613ca1 in internal_catch (tag=tag@entry=XIL(0x12390), func=func@entry=0x5891b0 <command_loop_2>, arg=arg@entry=XIL(0x90)) at ../../src/eval.c:1286
#25 0x000000000058916f in command_loop () at ../../src/keyboard.c:1141
#26 0x0000000000590be3 in recursive_edit_1 () at ../../src/keyboard.c:749
#27 0x0000000000590f5e in Frecursive_edit () at ../../src/keyboard.c:832
#28 0x000000000046a7ec in main (argc=6, argv=0x7fffffffdc88) at ../../src/emacs.c:2649
END BACKTRACE
VERSION INFO.
In GNU Emacs 31.0.50 (build 2, x86_64-pc-linux-gnu, X toolkit, cairo
version 1.18.0, Xaw3d scroll bars) of 2024-12-09 built on maher
Repository revision: based off 1098ae2896f
Windowing system distributor 'The X.Org Foundation', version 11.0.12101014
System Description: Gentoo Linux
Configured using:
'configure --with-x-toolkit=athena --with-native-compilation -C'
Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
LCMS2 LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 M17N_FLT MODULES NATIVE_COMP
NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF
TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XAW3D XDBE XIM XINPUT2 XPM
LUCID ZLIB
Important settings:
value of $LC_COLLATE: C
value of $LANG: en_US.utf8
value of $XMODIFIERS: @im=ibus
locale-coding-system: utf-8-unix
END VERSION INFO
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated.
2024-12-26 15:26 bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated Madhu
@ 2024-12-28 12:10 ` Eli Zaretskii
2025-01-08 13:11 ` Robert Pluim
0 siblings, 1 reply; 8+ messages in thread
From: Eli Zaretskii @ 2024-12-28 12:10 UTC (permalink / raw)
To: Madhu; +Cc: 75120
> From: Madhu <enometh@meer.net>
> Date: Thu, 26 Dec 2024 20:56:01 +0530
>
> Hello, Having heard about which-key mode I decided to try it.
>
> gdb --args ../build-xt-native/src/emacs -Q -eval '(which-key-mode 1)' -eval '(setq window-min-height 8)'
>
> 1. type C-x, wait 5 seconds, type C-g.
> 2. type C-x, wait 2 seconds for the 8 line frame with scrollbar, click the "up
> arrow" on the top of the scrollbar.
When I try this, Emacs signals an error, displaying "C-x
<vertical-scroll-bar> <mouse-1> is undefined" in the echo area. But
I'm not on X.
Can someone else reproduce the crash?
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated.
2024-12-28 12:10 ` Eli Zaretskii
@ 2025-01-08 13:11 ` Robert Pluim
2025-01-09 7:16 ` Eli Zaretskii
0 siblings, 1 reply; 8+ messages in thread
From: Robert Pluim @ 2025-01-08 13:11 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: Madhu, 75120
>>>>> On Sat, 28 Dec 2024 14:10:35 +0200, Eli Zaretskii <eliz@gnu.org> said:
>> From: Madhu <enometh@meer.net>
>> Date: Thu, 26 Dec 2024 20:56:01 +0530
>>
>> Hello, Having heard about which-key mode I decided to try it.
>>
>> gdb --args ../build-xt-native/src/emacs -Q -eval '(which-key-mode 1)' -eval '(setq window-min-height 8)'
>>
>> 1. type C-x, wait 5 seconds, type C-g.
>> 2. type C-x, wait 2 seconds for the 8 line frame with scrollbar, click the "up
>> arrow" on the top of the scrollbar.
Eli> When I try this, Emacs signals an error, displaying "C-x
Eli> <vertical-scroll-bar> <mouse-1> is undefined" in the echo area. But
Eli> I'm not on X.
Eli> Can someone else reproduce the crash?
Yes. In xt_action_hook:
x_send_scroll_bar_event (window_being_scrolled,
scroll_bar_end_scroll, 0, 0, false);
w = XWINDOW (window_being_scrolled);
bar = XSCROLL_BAR (w->vertical_scroll_bar); <-
w->vertical_scroll_bar == Qnil here
Although I have no clue what to do about it: I suspect the scrollbars
have been condemned by condemn_scroll_bars_hook, but then not
redeemed. Or maybe whatever is undoing or preventing the global
setting of "<vertical-scroll-bar> <mouse-1>" is responsible, but I
canʼt find where that is.
Robert
--
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated.
2025-01-08 13:11 ` Robert Pluim
@ 2025-01-09 7:16 ` Eli Zaretskii
2025-01-09 8:52 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
0 siblings, 1 reply; 8+ messages in thread
From: Eli Zaretskii @ 2025-01-09 7:16 UTC (permalink / raw)
To: Robert Pluim, martin rudalics; +Cc: enometh, 75120
> From: Robert Pluim <rpluim@gmail.com>
> Cc: Madhu <enometh@meer.net>, 75120@debbugs.gnu.org
> Date: Wed, 08 Jan 2025 14:11:57 +0100
>
> >>>>> On Sat, 28 Dec 2024 14:10:35 +0200, Eli Zaretskii <eliz@gnu.org> said:
>
> >> From: Madhu <enometh@meer.net>
> >> Date: Thu, 26 Dec 2024 20:56:01 +0530
> >>
> >> Hello, Having heard about which-key mode I decided to try it.
> >>
> >> gdb --args ../build-xt-native/src/emacs -Q -eval '(which-key-mode 1)' -eval '(setq window-min-height 8)'
> >>
> >> 1. type C-x, wait 5 seconds, type C-g.
> >> 2. type C-x, wait 2 seconds for the 8 line frame with scrollbar, click the "up
> >> arrow" on the top of the scrollbar.
>
> Eli> When I try this, Emacs signals an error, displaying "C-x
> Eli> <vertical-scroll-bar> <mouse-1> is undefined" in the echo area. But
> Eli> I'm not on X.
>
> Eli> Can someone else reproduce the crash?
>
> Yes. In xt_action_hook:
>
> x_send_scroll_bar_event (window_being_scrolled,
> scroll_bar_end_scroll, 0, 0, false);
> w = XWINDOW (window_being_scrolled);
> bar = XSCROLL_BAR (w->vertical_scroll_bar); <-
> w->vertical_scroll_bar == Qnil here
>
> Although I have no clue what to do about it: I suspect the scrollbars
> have been condemned by condemn_scroll_bars_hook, but then not
> redeemed. Or maybe whatever is undoing or preventing the global
> setting of "<vertical-scroll-bar> <mouse-1>" is responsible, but I
> canʼt find where that is.
Maybe we should simply do what xt_horizontal_action_hook does for the
horizontal scroll bar, i.e. do nothing if w->vertical_scroll_bar is
nil?
Martin, WDYT?
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated.
2025-01-09 7:16 ` Eli Zaretskii
@ 2025-01-09 8:52 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2025-01-09 9:26 ` Robert Pluim
0 siblings, 1 reply; 8+ messages in thread
From: martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2025-01-09 8:52 UTC (permalink / raw)
To: Eli Zaretskii, Robert Pluim; +Cc: enometh, 75120
> Maybe we should simply do what xt_horizontal_action_hook does for the
> horizontal scroll bar, i.e. do nothing if w->vertical_scroll_bar is
> nil?
I checked in a trivial fix for this. I'm not sure whether this will
leave some garbage behind - we probably should at least set
window_being_scrolled to nil if it is deleted (though how soon could it
be resurrected from a window configuration?) but I have no idea about
what to do with toolkit_scroll_bar_interaction. These static variables
in xterm.c are some sort of a mess.
martin
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated.
2025-01-09 8:52 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2025-01-09 9:26 ` Robert Pluim
2025-01-09 9:35 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
0 siblings, 1 reply; 8+ messages in thread
From: Robert Pluim @ 2025-01-09 9:26 UTC (permalink / raw)
To: martin rudalics; +Cc: Eli Zaretskii, 75120, enometh
>>>>> On Thu, 9 Jan 2025 09:52:24 +0100, martin rudalics <rudalics@gmx.at> said:
>> Maybe we should simply do what xt_horizontal_action_hook does for the
>> horizontal scroll bar, i.e. do nothing if w->vertical_scroll_bar is
>> nil?
martin> I checked in a trivial fix for this. I'm not sure whether this will
martin> leave some garbage behind - we probably should at least set
martin> window_being_scrolled to nil if it is deleted (though how soon could it
martin> be resurrected from a window configuration?) but I have no idea about
martin> what to do with toolkit_scroll_bar_interaction. These static variables
martin> in xterm.c are some sort of a mess.
Thanks, I didnʼt realize the window was being deleted. Fixes it for me.
Robert
--
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated.
2025-01-09 9:26 ` Robert Pluim
@ 2025-01-09 9:35 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2025-01-09 9:53 ` Robert Pluim
0 siblings, 1 reply; 8+ messages in thread
From: martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2025-01-09 9:35 UTC (permalink / raw)
To: Robert Pluim; +Cc: Eli Zaretskii, 75120, enometh
> martin> I checked in a trivial fix for this. I'm not sure whether this will
> martin> leave some garbage behind - we probably should at least set
> martin> window_being_scrolled to nil if it is deleted (though how soon could it
> martin> be resurrected from a window configuration?) but I have no idea about
> martin> what to do with toolkit_scroll_bar_interaction. These static variables
> martin> in xterm.c are some sort of a mess.
>
> Thanks, I didnʼt realize the window was being deleted. Fixes it for me.
If you have any ideas about the issues I mentioned above please tell me.
martin
^ permalink raw reply [flat|nested] 8+ messages in thread
* bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated.
2025-01-09 9:35 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2025-01-09 9:53 ` Robert Pluim
0 siblings, 0 replies; 8+ messages in thread
From: Robert Pluim @ 2025-01-09 9:53 UTC (permalink / raw)
To: martin rudalics; +Cc: Eli Zaretskii, 75120, enometh
>>>>> On Thu, 9 Jan 2025 10:35:49 +0100, martin rudalics <rudalics@gmx.at> said:
martin> I checked in a trivial fix for this. I'm not sure whether this will
martin> leave some garbage behind - we probably should at least set
martin> window_being_scrolled to nil if it is deleted (though how soon could it
martin> be resurrected from a window configuration?) but I have no idea about
martin> what to do with toolkit_scroll_bar_interaction. These static variables
martin> in xterm.c are some sort of a mess.
>>
>> Thanks, I didnʼt realize the window was being deleted. Fixes it for me.
martin> If you have any ideas about the issues I mentioned above please tell me.
I prefer not to look too hard at Xt related code 😀
Robert
--
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2025-01-09 9:53 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-26 15:26 bug#75120: 31.0.50; which-key crashes on xt if the scroll bar is activated Madhu
2024-12-28 12:10 ` Eli Zaretskii
2025-01-08 13:11 ` Robert Pluim
2025-01-09 7:16 ` Eli Zaretskii
2025-01-09 8:52 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2025-01-09 9:26 ` Robert Pluim
2025-01-09 9:35 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2025-01-09 9:53 ` Robert Pluim
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.