glx/windows: Avoid shadowing 'type' parameter of driwindowsCreateDrawable()

> ../src/glx/driwindows_glx.c: In function ‘driwindowsCreateDrawable’:
> ../src/glx/driwindows_glx.c:283:17: error: ‘type’ redeclared as different kind of symbol
>  283 |    unsigned int type;
>      |                 ^~~~
> ../src/glx/driwindows_glx.c:261:52: note: previous definition of ‘type’ with type ‘int’
>   261 |                          GLXDrawable drawable, int type,
>      |                                                ~~~~^~~~

Fixes: 887f5a6320 ("glx: add drawable type argument when create drawable")
Signed-off-by: Jon Turney <jon.turney@dronecode.org.uk>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/41421>
This commit is contained in:
Jon Turney 2026-02-03 18:09:34 +00:00 committed by Marge Bot
parent 4527b30a04
commit f9a7c50ed6

View file

@ -273,10 +273,10 @@ driwindowsCreateDrawable(struct glx_screen *base, XID xDrawable,
HBITMAP
*/
unsigned int type;
unsigned int drawable_type;
void *handle;
if (!XWindowsDRIQueryDrawable(psc->base.dpy, base->scr, drawable, &type, &handle))
if (!XWindowsDRIQueryDrawable(psc->base.dpy, base->scr, drawable, &drawable_type, &handle))
{
free(pdp);
return NULL;
@ -289,7 +289,7 @@ driwindowsCreateDrawable(struct glx_screen *base, XID xDrawable,
}
/* Create a new drawable */
pdp->windowsDrawable = windows_create_drawable(type, handle);
pdp->windowsDrawable = windows_create_drawable(drawable_type, handle);
if (!pdp->windowsDrawable) {
free(pdp);