aboutsummaryrefslogtreecommitdiffstats
path: root/kbfunc.c
diff options
context:
space:
mode:
authorokan2017-11-30 18:18:51 +0000
committerokan2017-11-30 18:18:51 +0000
commit17d1b3cbb69ad2e27ba8701380d36d8f78d1609f (patch)
treea4308b28dd4d85326012c0b5dc022e176525a428 /kbfunc.c
parente04212f686059843306cc4aee1f0be6ae87fa606 (diff)
downloadcwm-17d1b3cbb69ad2e27ba8701380d36d8f78d1609f.tar.gz
Revert r1.109 (Switch to XWindowEvent() pulling out events that match the mask
*and* window.) of mousefunc.c. When a client destroys itself while we are moving or resizing it, XWindowEvent() blocks. Found the hard way by Anton Lazarov, and Lea°hNeukirchen found the right bit to revert - thanks! Reverting since the reason to switch from XMaskEvent was unclear.
Diffstat (limited to 'kbfunc.c')
-rw-r--r--kbfunc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kbfunc.c b/kbfunc.c
index 5fa0c88..13460e3 100644
--- a/kbfunc.c
+++ b/kbfunc.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: kbfunc.c,v 1.149 2017/07/14 18:01:46 okan Exp $
+ * $OpenBSD: kbfunc.c,v 1.150 2017/11/30 18:18:51 okan Exp $
*/
#include <sys/types.h>
@@ -168,7 +168,7 @@ kbfunc_client_move_mb(void *ctx, struct cargs *cargs)
menu_windraw(sc, cc->win, "%4d, %-4d", cc->geom.x, cc->geom.y);
while (move) {
- XWindowEvent(X_Dpy, cc->win, MOUSEMASK, &ev);
+ XMaskEvent(X_Dpy, MOUSEMASK, &ev);
switch (ev.type) {
case MotionNotify:
/* not more than 60 times / second */
@@ -256,7 +256,7 @@ kbfunc_client_resize_mb(void *ctx, struct cargs *cargs)
menu_windraw(sc, cc->win, "%4d x %-4d", cc->dim.w, cc->dim.h);
while (resize) {
- XWindowEvent(X_Dpy, cc->win, MOUSEMASK, &ev);
+ XMaskEvent(X_Dpy, MOUSEMASK, &ev);
switch (ev.type) {
case MotionNotify:
/* not more than 60 times / second */