summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorraveit65 <[email protected]>2017-05-02 13:21:51 +0200
committerraveit65 <[email protected]>2017-05-10 16:24:13 +0200
commite1aa4ec7d6a96b7244a7a471c1b1e18d59935811 (patch)
treefa85c6b2822aa5870b7c1f8a731f8e7d122d29a6
parent3b69fd200912e27ce64caf3bf5d4338aab73177b (diff)
downloadmarco-e1aa4ec7d6a96b7244a7a471c1b1e18d59935811.tar.bz2
marco-e1aa4ec7d6a96b7244a7a471c1b1e18d59935811.tar.xz
Revert "compositor: fix possible crash closing/destroying window"
This reverts commit 768fdd8d3852e67555a585da28b6404a97853cbd. Fixes https://github.com/mate-desktop/marco/issues/251
-rw-r--r--src/compositor/compositor-private.h3
-rw-r--r--src/compositor/compositor-xrender.c34
-rw-r--r--src/compositor/compositor.c4
3 files changed, 9 insertions, 32 deletions
diff --git a/src/compositor/compositor-private.h b/src/compositor/compositor-private.h
index 1eef9633..fed5e8e7 100644
--- a/src/compositor/compositor-private.h
+++ b/src/compositor/compositor-private.h
@@ -55,9 +55,6 @@ struct _MetaCompositor
MetaScreen *screen,
MetaWindow *window);
- void (*free_window) (MetaCompositor *compositor,
- MetaWindow *window);
-
void (*maximize_window) (MetaCompositor *compositor,
MetaWindow *window);
void (*unmaximize_window) (MetaCompositor *compositor,
diff --git a/src/compositor/compositor-xrender.c b/src/compositor/compositor-xrender.c
index 1da598c5..c65a7eb3 100644
--- a/src/compositor/compositor-xrender.c
+++ b/src/compositor/compositor-xrender.c
@@ -2694,38 +2694,23 @@ xrender_end_move (MetaCompositor *compositor,
#ifdef HAVE_COMPOSITE_EXTENSIONS
#endif
}
-#endif /* 0 */
static void
xrender_free_window (MetaCompositor *compositor,
MetaWindow *window)
{
#ifdef HAVE_COMPOSITE_EXTENSIONS
- MetaCompositorXRender *xrc;
- MetaFrame *frame;
- Window xwindow;
-
- xrc = (MetaCompositorXRender *) compositor;
- frame = meta_window_get_frame (window);
- xwindow = None;
-
- if (frame)
- {
- xwindow = meta_frame_get_xwindow (frame);
- }
- else
- {
- /* FIXME: When an undecorated window is hidden this is called, but the
- * window does not get readded if it is subsequentally shown again. See:
- * http://bugzilla.gnome.org/show_bug.cgi?id=504876
- */
- /* xwindow = meta_window_get_xwindow (window); */
- }
-
- if (xwindow != None)
- destroy_win (xrc->display, xwindow, FALSE);
+ /* FIXME: When an undecorated window is hidden this is called,
+ but the window does not get readded if it is subsequentally shown again
+ See http://bugzilla.gnome.org/show_bug.cgi?id=504876
+
+ I don't *think* theres any need for this call anyway, leaving it out
+ does not seem to cause any side effects so far, but I should check with
+ someone who understands more. */
+ /* destroy_win (compositor->display, window->xwindow, FALSE); */
#endif
}
+#endif /* 0 */
static void
xrender_process_event (MetaCompositor *compositor,
@@ -3052,7 +3037,6 @@ static MetaCompositor comp_info = {
xrender_get_window_pixmap,
#endif
xrender_set_active_window,
- xrender_free_window,
xrender_maximize_window,
xrender_unmaximize_window,
};
diff --git a/src/compositor/compositor.c b/src/compositor/compositor.c
index 4d3f370b..263606e5 100644
--- a/src/compositor/compositor.c
+++ b/src/compositor/compositor.c
@@ -172,10 +172,6 @@ void meta_compositor_end_move (MetaCompositor *compositor,
void meta_compositor_free_window (MetaCompositor *compositor,
MetaWindow *window)
{
-#ifdef HAVE_COMPOSITE_EXTENSIONS
- if (compositor && compositor->free_window)
- compositor->free_window (compositor, window);
-#endif
}
void