kitty/glfw
copilot-swe-agent[bot] 877be65447
Fix crashes when moving tab between OS windows (issue #9677)
Wayland (glfw/wl_window.c):
- Fix out-of-bounds access in send_drag_data: look up item by MIME type
  instead of using the data-request index i to index _glfw.drag.items[].
  The compositor calls drag_source_send once per target window entered,
  so _glfw.wl.drag.count grows independently of item_count, causing
  _glfw.drag.items[i] to be out-of-bounds on the second drag, yielding a
  garbage optional_data pointer that made write() fail with EFAULT.
- Fix protocol error "Drag has not ended": change on_fail and the
  GLFW_DRAG_DATA_REQUEST error path to call finish_drag_write(i)+return
  instead of cancel_drag(), which was calling wl_data_source_destroy()
  before the compositor ended the drag, violating the Wayland protocol.
- Fix double-free of dr.pending_data: null the pointer after free and
  add cleanup to finish_drag_write().
- Fix missing finish_drag_write() after a full write in data-request
  mode, which left the pipe open causing the target to wait for EOF.

X11 (glfw/x11_window.c):
- Wrap XSendEvent() calls in send_xdnd_enter/position/leave/drop with
  _glfwGrabErrorHandlerX11()/_glfwReleaseErrorHandlerX11(). A target
  window destroyed between discovery and message delivery produced a
  BadWindow error that hit the default X11 abort handler. Now handled
  gracefully by clearing current_target or cancelling the drag."

Fixes #9677
Fixes #9683
2026-03-17 08:53:17 +05:30
..
__init__.py
backend_utils.c Refactor drop API and implement it on Wayland 2026-02-08 22:05:14 +05:30
backend_utils.h DRYer 2026-02-07 23:11:42 +05:30
cocoa_displaylink.m Nano-optimisation: Avoid using a block with GCD 2025-10-22 13:40:42 +05:30
cocoa_init.m Fix macOS keyboard focus not restored when switching back from another space 2026-03-15 14:57:46 +05:30
cocoa_joystick.h
cocoa_joystick.m
cocoa_monitor.m Add some missing assertions 2025-08-16 07:38:54 +05:30
cocoa_platform.h Fix GLFW drop API to always present full original MIME type list to callbacks 2026-03-10 20:10:44 +05:30
cocoa_window.m Fix: Dictation does not start on double Fn key press on Mac OS 2026-03-15 01:15:05 +03:00
context.c
dbus_glfw.c Linux: Handle desktop settings portals that are so old they don't implement ReadOne 2025-05-08 15:22:42 +05:30
dbus_glfw.h Linux: Handle desktop settings portals that are so old they don't implement ReadOne 2025-05-08 15:22:42 +05:30
egl_context.c Fallback to eglGetDisplay() when eglGetPlatformDisplayEXT() returns EGL_NO_DISPLAY 2025-08-16 08:13:40 +05:30
egl_context.h
glfw.py Merge branch 'titlebar-only-wayland' of https://github.com/antoinecellerier/kitty 2026-02-23 19:19:30 +05:30
glfw3.h Wayland: Implement ridiculous workaround for broken dnd 2026-02-22 16:24:46 +05:30
glx_context.c Add some missing assertions 2025-08-16 07:38:54 +05:30
glx_context.h
ibus_glfw.c Linux: Handle desktop settings portals that are so old they don't implement ReadOne 2025-05-08 15:22:42 +05:30
ibus_glfw.h
init.c Wire up clipboard lost events 2025-03-12 09:26:36 +05:30
input.c Fix GLFW drop API to always present full original MIME type list to callbacks 2026-03-10 20:10:44 +05:30
internal.h Wayland: Implement ridiculous workaround for broken dnd 2026-02-22 16:24:46 +05:30
kwin-blur-v1.xml
linux_desktop_settings.c ... 2025-11-22 20:03:01 +05:30
linux_desktop_settings.h Function to get the current system color theme 2024-11-07 12:47:06 +05:30
linux_joystick.c
linux_joystick.h
linux_notify.c Linux: Handle desktop settings portals that are so old they don't implement ReadOne 2025-05-08 15:22:42 +05:30
linux_notify.h
main_loop.h
mappings.h
memfd.h
momentum-scroll.c Dont send non-finger based zero size scroll events on Wayland 2026-02-17 11:23:49 +05:30
monitor.c Improve handling of output names 2025-05-13 15:29:37 +05:30
monotonic.c
nsgl_context.h
nsgl_context.m Cleanup previous PR 2026-02-23 07:44:58 +05:30
null_init.c
null_joystick.c
null_joystick.h
null_monitor.c
null_platform.h
null_window.c Cleanup previous PR 2026-02-22 15:36:10 +05:30
osmesa_context.c Add some missing assertions 2025-08-16 07:38:54 +05:30
osmesa_context.h
posix_thread.c
posix_thread.h
source-info.json ... 2026-02-22 16:48:59 +05:30
vulkan.c
window.c macOS: When toggling in the quick access terminal move it to the currently active screen 2025-09-22 20:04:42 +05:30
wl_client_side_decorations.c Support hide_window_decorations titlebar-only on Wayland 2026-02-08 19:49:44 +01:00
wl_client_side_decorations.h Wayland: Fix incorrect window size calculation when transitioning from fullscreen to non-fullscreen with client side decorations 2025-07-17 20:36:38 +05:30
wl_cursors.c
wl_cursors.h
wl_init.c Wayland: Fix momentum scrolling not working on compositors that send a stop frame with no axis information 2026-03-13 08:47:45 +05:30
wl_monitor.c Add some missing assertions 2025-08-16 07:38:54 +05:30
wl_platform.h Wayland: Fix momentum scrolling not working on compositors that send a stop frame with no axis information 2026-03-13 08:47:45 +05:30
wl_text_input.c
wl_text_input.h
wl_window.c Fix crashes when moving tab between OS windows (issue #9677) 2026-03-17 08:53:17 +05:30
wlr-layer-shell-unstable-v1.xml
x11_init.c Make XI2 scroll offset type detection more robust 2026-03-12 21:44:20 +05:30
x11_monitor.c Add some missing assertions 2025-08-16 07:38:54 +05:30
x11_platform.h Make XI2 scroll offset type detection more robust 2026-03-12 21:44:20 +05:30
x11_window.c Fix crashes when moving tab between OS windows (issue #9677) 2026-03-17 08:53:17 +05:30
xkb-compat-shim.h
xkb_glfw.c Linux: Rather than crashing on systems that give us broken keymaps just ignore key events 2026-01-30 19:00:46 +05:30
xkb_glfw.h