This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch master
in repository e16.

View the commit online.

commit 3b07d3f12ac28051b7d6bee35a5fcae981f9b006
Author: Kim Woelders <[email protected]>
AuthorDate: Sat Jul 2 18:20:28 2022 +0200

    events: Discard all but last reparent event in queue for window
    
    Processing obsolete reparent events may cause trouble.
    However, this is probably no guarantee that all obsolete reparent events
    are discarded.
---
 src/events.c | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/src/events.c b/src/events.c
index 642726da..e4a7c366 100644
--- a/src/events.c
+++ b/src/events.c
@@ -767,6 +767,27 @@ EventsCompress(XEvent * evq, int count)
 	   loop_quit_DestroyNotify:
 	     break;
 
+	  case ReparentNotify:
+	     /* Discard all but last reparent event for window */
+	     n = 0;
+	     for (j = i - 1; j >= 0; j--)
+	       {
+		  ev2 = evq + j;
+		  if (ev2->type == type &&
+		      ev2->xany.window == ev->xany.window &&
+		      ev2->xreparent.window == ev->xreparent.window)
+		    {
+		       n++;
+		       ev2->type = 0;
+		    }
+	       }
+#if ENABLE_DEBUG_EVENTS
+	     if (n && EDebug(EDBUG_TYPE_COMPRESSION))
+		Eprintf("%s: n=%4d %s %#lx\n", __func__,
+			n, EventName(type), ev->xreparent.window);
+#endif
+	     break;
+
 	  case Expose:
 	     n = 0;
 	     xa = ev->xexpose.x;

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

Reply via email to