Hmm... Looks like a unified diff to me... The text leading up to this was: -------------------------- |From 9c020a20a2e1091e8b47edfea5e8795d8b451bc9 Mon Sep 17 00:00:00 2001 |From: Lukasz Kasprzak |Date: Fri, 17 Jul 2026 15:45:22 +0200 |Subject: [PATCH] keychord: bind a sequence of keys, and dispatch events while | waiting | |Original keychord patch by Hai Nguyen , updated for |dwm 6.4+ grabkeys() by Aaron Zueger . This |revision rebases onto dwm 6.8 and fixes an event-loss bug in the chord |wait loop. | |The wait loop used to discard every event that was not a KeyPress: | | while (running && !XNextEvent(dpy, &event) && !ran) | if(event.type == KeyPress) | break; | |Two consequences, both reproduced on Xephyr: | |1. Unrecoverable input freeze. grabbuttons() grabs unfocused clients | GrabModeSync/GrabModeSync, so clicking one freezes pointer AND | keyboard until the grabbing client calls XAllowEvents. dwm does that | in buttonpress() -- but if the ButtonPress is discarded here, | buttonpress() never runs. The grab stays frozen forever and the loop | can never exit, because a frozen keyboard cannot deliver the KeyPress | it is waiting for. Only killing dwm ends it; XSendEvent is discarded | by this same loop and XTEST queues behind the frozen device. | Repro: press a chord prefix, then click any unfocused client. | Observed: XGrabKeyboard -> GrabFrozen, XQueryPointer -> Button1 held. | |2. Orphaned windows. A MapRequest arriving mid-chord is dropped, so a | window opening during a chord is never managed. DestroyNotify, | Expose and ConfigureRequest are lost the same way. | |Dispatch through handler[] as run() does, breaking on KeyPress before |dispatch so keypress() cannot recurse. The `&& !ran` term is dropped: |ran is always 0 on entry and nothing in the body can set it. |--- | config.def.h | 81 ++++++++++++++++++++++++++-------------------------- | dwm.c | 79 +++++++++++++++++++++++++++++++++++++++++--------- | 2 files changed, 106 insertions(+), 54 deletions(-) | |diff --git a/config.def.h b/config.def.h |index 81c3fc0..7c7ec36 100644 |--- a/config.def.h |+++ b/config.def.h -------------------------- Patching file config.def.h using Plan A... Hunk #1 succeeded at 47. Hunk #2 succeeded at 61. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |diff --git a/dwm.c b/dwm.c |index 53b393e..243b12c 100644 |--- a/dwm.c |+++ b/dwm.c -------------------------- Patching file dwm.c using Plan A... Hunk #1 succeeded at 101. Hunk #2 succeeded at 271. Hunk #3 succeeded at 960. Hunk #4 succeeded at 971. Hunk #5 succeeded at 1009. Hmm... Ignoring the trailing garbage. done