Fix strange effects on desktop caused by 4a14668772a37b18a9aceb8951ece260084bc96e
authorNikolas Garofil <garo@dunaldi.garofil.be>
Tue, 14 Jul 2009 16:10:43 +0000 (18:10 +0200)
committerNikolas Garofil <garo@dunaldi.garofil.be>
Tue, 14 Jul 2009 16:10:43 +0000 (18:10 +0200)
src/conky.c
src/x11.c

index 354bf1a..9d5f064 100644 (file)
@@ -7478,12 +7478,12 @@ void clean_up(void)
        }
 #ifdef X11
        if (x_initialised == YES) {
+               destroy_window();
                free_fonts();
                if(x11_stuff.region) {
                        XDestroyRegion(x11_stuff.region);
                        x11_stuff.region = NULL;
                }
-               destroy_window();
                XClearWindow(display, RootWindow(display, screen));
                XCloseDisplay(display);
                if(info.x11.desktop.all_names) {
index 6da619e..5364dce 100644 (file)
--- a/src/x11.c
+++ b/src/x11.c
@@ -194,7 +194,6 @@ void set_transparent_background(Window win)
 
 void destroy_window(void)
 {
-       XDestroyWindow(display, window.window);
        XFreeGC(display, window.gc);
        memset(&window, 0, sizeof(struct conky_window));
 }