summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristopher Jeffrey <chjjeffrey@gmail.com>2012-09-08 21:04:44 -0500
committerChristopher Jeffrey <chjjeffrey@gmail.com>2012-09-08 21:04:44 -0500
commite29714d41dabf9db6eea16583994ea061dba8505 (patch)
treeb58a75afd8c6f8ffc9cec0e51ae1d0c1f18b26d8
parentc10cd64f1fb6fc083b81981b561824b5da5275f4 (diff)
downloadtdebase-e29714d41dabf9db6eea16583994ea061dba8505.tar.gz
tdebase-e29714d41dabf9db6eea16583994ea061dba8505.zip
add richardgv's patch. see #31.
-rw-r--r--compton.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/compton.c b/compton.c
index b81117d46..021174804 100644
--- a/compton.c
+++ b/compton.c
@@ -1578,6 +1578,11 @@ add_win(Display *dpy, Window id, Window prev, Bool override_redirect) {
if (!new) return;
+ if (find_win(dpy, id)) {
+ free(new);
+ return;
+ }
+
if (prev) {
for (p = &list; *p; p = &(*p)->next) {
if ((*p)->id == prev && !(*p)->destroyed)