diff --git a/gdk/x11/gdkglcontext-x11.c b/gdk/x11/gdkglcontext-x11.c
index accc8a5..e75f7b8 100644
--- a/gdk/x11/gdkglcontext-x11.c
+++ b/gdk/x11/gdkglcontext-x11.c
@@ -586,11 +586,11 @@ find_fbconfig_for_visual (GdkDisplay        *display,
   attrs[i++] = GL_TRUE;
 
   attrs[i++] = GLX_RED_SIZE;
-  attrs[i++] = gdk_visual_get_bits_per_rgb (visual);
+  attrs[i++] = 1;
   attrs[i++] = GLX_GREEN_SIZE;
-  attrs[i++] = gdk_visual_get_bits_per_rgb (visual);;
+  attrs[i++] = 1;
   attrs[i++] = GLX_BLUE_SIZE;
-  attrs[i++] = gdk_visual_get_bits_per_rgb (visual);;
+  attrs[i++] = 1;
 
   use_rgba = (visual == gdk_screen_get_rgba_visual (gdk_display_get_default_screen (display)));
 
@@ -807,9 +807,7 @@ gdk_x11_window_create_gl_context (GdkWindow    *window,
 
       if (GDK_X11_DISPLAY (display)->glx_version >= 13)
 	{
-	  info->glx_drawable = glXCreateWindow (dpy, config,
-						gdk_x11_window_get_xid (window->impl_window),
-						NULL);
+	  info->glx_drawable = None;
 	  info->dummy_glx = glXCreateWindow (dpy, config, info->dummy_xwin, NULL);
 	}
 
