]> git.eshelyaron.com Git - emacs.git/commitdiff
Update input_pending after deferring selection requests
authorPo Lu <luangruo@yahoo.com>
Sat, 25 Jun 2022 12:07:35 +0000 (20:07 +0800)
committerPo Lu <luangruo@yahoo.com>
Sat, 25 Jun 2022 12:08:52 +0000 (20:08 +0800)
* src/xterm.c (x_defer_selection_requests): If kbd_fetch_ptr
moved, update input_pending.  Bug found calling
`input-pending-p' inside the DND movement function.

src/xterm.c

index 7f43e21e88414fcb4de67d5ec7442419f0435be4..7d5794bdd7a75348aecc2f96857bc04df15bb0dc 100644 (file)
@@ -842,7 +842,13 @@ x_defer_selection_requests (void)
                 avoids exhausting the keyboard buffer with some
                 over-enthusiastic clipboard managers.  */
              if (!between)
-               kbd_fetch_ptr = X_NEXT_KBD_EVENT (event);
+               {
+                 kbd_fetch_ptr = X_NEXT_KBD_EVENT (event);
+
+                 /* `detect_input_pending' will then recompute
+                    whether or not pending input events exist.  */
+                 input_pending = false;
+               }
            }
          else
            between = true;