Commit 9214bae
dnd kitten: remove empty-payload EOF QueueDnDData calls for thumbnails
The empty-payload second QueueDnDData call in set_drag_image() and
set_drag_image_text() triggered base64_decode_stream on an already-
completed (padded) stream, which returns failure. This caused cancel_drag
→ drag_free_offer to run, destroying all drag state before drag_start
was called from t=P:x=-1. As a result, drag_remote_file_data found no
item with requested_remote_files set and aborted with EINVAL.
The empty EOF call was never needed: drag_add_image only accumulates
decoded bytes; the actual image processing happens later in drag_start.
This mirrors the same fix already applied to the MIME pre-send path.
Agent-Logs-Url: https://github.com/kovidgoyal/kitty/sessions/8bb89dc9-fd72-41c5-892b-2a15c658b313
Co-authored-by: kovidgoyal <1308621+kovidgoyal@users.noreply.github.com>1 parent b9a8784 commit 9214bae
1 file changed
Lines changed: 3 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
116 | 116 | | |
117 | 117 | | |
118 | 118 | | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
| 119 | + | |
123 | 120 | | |
124 | 121 | | |
125 | 122 | | |
| |||
151 | 148 | | |
152 | 149 | | |
153 | 150 | | |
154 | | - | |
| 151 | + | |
155 | 152 | | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
| 153 | + | |
160 | 154 | | |
161 | 155 | | |
162 | 156 | | |
| |||
0 commit comments