From: Dmitry Antipov Date: Mon, 2 Sep 2013 10:37:06 +0000 (+0400) Subject: * xterm.c (x_last_mouse_movement_time) [X_MOTION_HISTORY]: Fix last change. X-Git-Tag: emacs-24.3.90~173^2^2~42^2~45^2~387^2~1686^2~19 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=def74bdc4849c1bae460ffadd47072a7171215b3;p=emacs.git * xterm.c (x_last_mouse_movement_time) [X_MOTION_HISTORY]: Fix last change. --- diff --git a/src/xterm.c b/src/xterm.c index bc7dd639c6b..1870aae5a6d 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -3727,11 +3727,15 @@ x_last_mouse_movement_time (struct frame *f) { Time t; int nevents; - XTimeCoord *xtc = XGetMotionEvents (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), - 1, last_user_time, &nevents); + XTimeCoord *xtc; + + block_input (); + xtc = XGetMotionEvents (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), + 1, last_user_time, &nevents); eassert (xtc && nevents > 0); t = xtc[nevents - 1].time; XFree (xtc); + unblock_input (); return t; }