winex11: Push down variable attrib down to where i create_gl_drawable.

Gerald Pfeifer gerald at pfeifer.com
Fri Jan 25 19:07:13 CST 2013


The following change

   commit 951415b602743af897371e077fb47f56f6461dd7
   Author: Alexandre Julliard <julliard at winehq.org>
   Date:   Wed Jan 23 13:35:30 2013 +0100

   winex11: Store the client window in the window data again, now that it 
   can be accessed from all threads.

causes a compiler warning about an unused variable in GCC 4.8.0,
and indeed with SONAME_LIBXCOMPOSITE not set we need the patch 
below.

Gerald

---
 dlls/winex11.drv/opengl.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/dlls/winex11.drv/opengl.c b/dlls/winex11.drv/opengl.c
index dded333..ee62402 100644
--- a/dlls/winex11.drv/opengl.c
+++ b/dlls/winex11.drv/opengl.c
@@ -1222,8 +1222,6 @@ static void free_gl_drawable( struct gl_drawable *gl )
  */
 static BOOL create_gl_drawable( HWND hwnd, HWND parent, struct gl_drawable *gl )
 {
-    XSetWindowAttributes attrib;
-
     gl->drawable = 0;
 
     if (GetAncestor( hwnd, GA_PARENT ) == GetDesktopWindow())  /* top-level window */
@@ -1241,6 +1239,7 @@ static BOOL create_gl_drawable( HWND hwnd, HWND parent, struct gl_drawable *gl )
     else if(usexcomposite)
     {
         static Window dummy_parent;
+        XSetWindowAttributes attrib;
 
         attrib.override_redirect = True;
         if (!dummy_parent)
-- 
1.8.1



More information about the wine-patches mailing list