]> git.eshelyaron.com Git - emacs.git/commit
Handle invalid frame_or_window slots in tty input events (Bug#78966)
authorMartin Rudalics <rudalics@gmx.at>
Wed, 9 Jul 2025 07:52:01 +0000 (09:52 +0200)
committerEshel Yaron <me@eshelyaron.com>
Thu, 24 Jul 2025 07:52:26 +0000 (09:52 +0200)
commit087b276433ead968f17246956bb7fe435a7e8d23
tree821b319da252d444a22f293684cf8896a75b53d4
parent90a6c7dc7cf6d971dd2033ba13a5b08e5c80c091
Handle invalid frame_or_window slots in tty input events (Bug#78966)

* src/frame.c (make_terminal_frame): Initialize terminal's
top_frame slot if it has not been set up yet (Bug#78966).
* src/keyboard.c (kbd_buffer_get_event): Do not assume that the
event's frame_or_window slot always produces a valid frame
(Bug#78966).
(tty_read_avail_input): Try to make sure that the input event we
create has a valid frame_or_window slot (Bug#78966).  Add assertion
to that purpose.

(cherry picked from commit 2fc402cb0bb62f3c401528246742501a8d42bf14)
src/frame.c
src/keyboard.c