mesa/src/glx
Adam Jackson f8d3c222db glx: Reflow MakeContextCurrent a little
First, move a few early-out checks up since they don't need to take the
GLX lock. Second, move garbage collecting deleted contexts up to
immediately after they are unbound. This fixes a memory leak, albeit a
difficult one to hit, in the case where you switch away from a deleted
context but switching to the new one errors out. In that case we would
leak the deleted context, since it's been unbound from all threads and
there's no longer an XID for it.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20549>
2023-01-13 19:59:26 +00:00
..
apple glapi: #include "util/glheader.h" in glapi_priv.h and glapitable.h directly 2022-11-03 16:07:31 +00:00
tests glx: Remove glx_context::screen 2023-01-13 19:59:26 +00:00
windows glx: Remove windows' stub {bind,release}_text_image context hooks 2021-03-19 11:13:07 -04:00
applegl_glx.c glx: Clean up some funny business from context bind/unbind 2023-01-13 19:59:26 +00:00
clientattrib.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
clientinfo.c glx: Only compute client GL extensions for indirect contexts 2023-01-03 23:36:26 +00:00
compsize.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
create_context.c glx: clean-ups in create_context.c 2022-10-27 03:26:08 +00:00
dri2.c replace 0 with NULL for NULL pointers 2022-01-10 22:53:32 +00:00
dri2.h
dri2_glx.c glx: Clean up some funny business from context bind/unbind 2023-01-13 19:59:26 +00:00
dri2_priv.h dri: Introduce internal Mesa DRI driver loader extension. 2022-12-05 19:26:41 +00:00
dri3_glx.c glx: Clean up some funny business from context bind/unbind 2023-01-13 19:59:26 +00:00
dri3_priv.h glx/dri3: Simplify protocol version tracking 2023-01-13 19:59:26 +00:00
dri_common.c glx: Remove support for glXGetDriverConfig for old drivers 2023-01-13 19:59:26 +00:00
dri_common.h glx: Use the new no-error driver interface 2022-02-04 18:36:24 +00:00
dri_common_interop.c glx: Implement the new flush method 2022-11-02 18:11:41 +00:00
dri_common_query_renderer.c
drisw_glx.c glx: Clean up some funny business from context bind/unbind 2023-01-13 19:59:26 +00:00
drisw_priv.h dri: Introduce internal Mesa DRI driver loader extension. 2022-12-05 19:26:41 +00:00
driwindows_glx.c glx: Clean up some funny business from context bind/unbind 2023-01-13 19:59:26 +00:00
eval.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
g_glxglvnddispatchfuncs.c glx: init __GLXvendorInfo to NULL 2021-04-29 20:34:25 +00:00
g_glxglvnddispatchindices.h glx: Provide glvnd wrapper for glXSwapIntervalEXT 2021-01-22 22:34:23 -08:00
glx_error.c glx: Stash a copy of the XExtCodes in the glx_display 2021-04-29 20:34:25 +00:00
glx_error.h
glx_pbuffer.c glx: Require GLX 1.3 2023-01-03 23:36:26 +00:00
glx_query.c glx: Remove unused opcode argument to __glX{Get,QueryServer}String 2021-04-29 20:34:25 +00:00
glxclient.h glx: Clean up some funny business from context bind/unbind 2023-01-13 19:59:26 +00:00
glxcmds.c glx: Remove glx_context::screen 2023-01-13 19:59:26 +00:00
glxconfig.c glx: set max values for pbuffer width / height 2022-05-17 07:21:34 +00:00
glxconfig.h glx: Fix GLX_NV_float_buffer fbconfig handling 2021-12-16 22:05:20 +00:00
glxcurrent.c glx: Reflow MakeContextCurrent a little 2023-01-13 19:59:26 +00:00
glxext.c glx: Only compute client GL extensions for indirect contexts 2023-01-03 23:36:26 +00:00
glxextensions.c glx: Remove the GetProcAddress special case for indirect rendering 2023-01-03 23:36:26 +00:00
glxextensions.h glx: Remove the GetProcAddress special case for indirect rendering 2023-01-03 23:36:26 +00:00
glxglvnd.c
glxglvnd.h
glxglvnddispatchfuncs.h
glxhash.c Revert "glx: Use XSaveContext, delete glxhash.c" 2022-09-12 21:18:15 +00:00
glxhash.h Revert "glx: Use XSaveContext, delete glxhash.c" 2022-09-12 21:18:15 +00:00
indirect_glx.c glx: Clean up some funny business from context bind/unbind 2023-01-13 19:59:26 +00:00
indirect_init.h
indirect_texture_compression.c
indirect_transpose_matrix.c
indirect_vertex_array.c glapi: remove EXT and ARB suffixes from Draw functions 2022-10-19 04:23:05 +00:00
indirect_vertex_array.h
indirect_vertex_array_priv.h
indirect_vertex_program.c
indirect_window_pos.c
meson.build Revert "glx: Use XSaveContext, delete glxhash.c" 2022-09-12 21:18:15 +00:00
packrender.h glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
packsingle.h glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
pixel.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
pixelstore.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
query_renderer.c replace 0 with NULL for NULL pointers 2022-01-10 22:53:32 +00:00
render2.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
renderpix.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
single2.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
singlepix.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
vertarr.c glx: Replace FreeB 2.0 text with SPDX-License-Identifier: SGI-B-2.0 2023-01-03 23:36:26 +00:00
xfont.c glx: Remove glx_context::screen 2023-01-13 19:59:26 +00:00