mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 00:38:48 +02:00
xlib: use XMesaDestroyVisual when destroying display visuals
destroy_visuals_on_display() frees XMesaVisual objects directly, but XMesaVisual has a dedicated destructor. Related: https://gitlab.freedesktop.org/mesa/mesa/-/issues/14947 Reviewed-by: Adam Jackson <ajax@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40422>
This commit is contained in:
parent
447a1d2e8d
commit
8131af3f77
1 changed files with 1 additions and 1 deletions
|
|
@ -602,7 +602,7 @@ destroy_visuals_on_display(Display *dpy)
|
|||
if (VisualTable[i]->display == dpy) {
|
||||
/* remove this visual */
|
||||
int j;
|
||||
free(VisualTable[i]);
|
||||
XMesaDestroyVisual(VisualTable[i]);
|
||||
for (j = i; j < NumVisuals - 1; j++)
|
||||
VisualTable[j] = VisualTable[j + 1];
|
||||
NumVisuals--;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue