From 00155d409b3b839f85f7201face93b06a64b56d6 Mon Sep 17 00:00:00 2001 From: Laurent Aimar Date: Thu, 16 Apr 2009 22:26:48 +0200 Subject: [PATCH] Fixed xcb resize support. Yep, there is some black magic here ;) --- modules/video_output/xcb/xcb.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/video_output/xcb/xcb.c b/modules/video_output/xcb/xcb.c index db6f0d6555..3c52f776d8 100644 --- a/modules/video_output/xcb/xcb.c +++ b/modules/video_output/xcb/xcb.c @@ -427,6 +427,8 @@ static int Init (vout_thread_t *vout) const xcb_screen_t *screen = p_sys->screen; unsigned x, y, width, height; + I_OUTPUTPICTURES = 0; + /* Determine parent window and size */ if (vout->b_fullscreen) { @@ -534,8 +536,8 @@ static void Deinit (vout_thread_t *vout) { vout_sys_t *p_sys = vout->p_sys; - while (I_OUTPUTPICTURES > 0) - PictureDeinit (PP_OUTPUTPICTURE[--I_OUTPUTPICTURES]); + for (int i = 0; i < I_OUTPUTPICTURES; i++) + PictureDeinit (PP_OUTPUTPICTURE[i]); xcb_unmap_window (p_sys->conn, p_sys->window); xcb_destroy_window (p_sys->conn, p_sys->window); -- 2.39.5