I finally learned how to make the diff using cvs :-)
Index: client.c =================================================================== RCS file: /cvs/xenocara/app/cwm/client.c,v retrieving revision 1.234 diff -u -p -r1.234 client.c --- client.c 6 Feb 2017 18:10:28 -0000 1.234 +++ client.c 10 Apr 2017 14:16:31 -0000 @@ -645,9 +645,11 @@ match: void client_cycle(struct screen_ctx *sc, int flags) { - struct client_ctx *newcc, *oldcc; + struct client_ctx *newcc, *oldcc, *prevcc; int again = 1; + prevcc = TAILQ_FIRST(&sc->clientq); + /* For X apps that ignore events. */ XGrabKeyboard(X_Dpy, sc->rootwin, True, GrabModeAsync, GrabModeAsync, CurrentTime); @@ -686,6 +688,7 @@ client_cycle(struct screen_ctx *sc, int /* reset when cycling mod is released. XXX I hate this hack */ sc->cycling = 1; client_ptrsave(oldcc); + client_raise(prevcc); client_raise(newcc); if (!client_inbound(newcc, newcc->ptr.x, newcc->ptr.y)) { newcc->ptr.x = newcc->geom.w / 2;