glx: fix xshm check to init xshm_opcode.

Found and proposed by Ray Strode (halfline)

Fixes: 68e8940114 ("glx/drisw: use xcb instead of X to query connection")
Reviewed-by: Emma Anholt <emma@anholt.net>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20188>
This commit is contained in:
Dave Airlie
2022-12-07 05:11:47 +10:00
committed by Marge Bot
parent 2ccf481c17
commit 57b7102ef9
+1
View File
@@ -874,6 +874,7 @@ check_xshm(Display *dpy)
shm_cookie = xcb_query_extension(c, 7, "MIT-SHM");
shm_reply = xcb_query_extension_reply(c, shm_cookie, NULL);
xshm_opcode = shm_reply->major_opcode;
has_mit_shm = shm_reply->present;
free(shm_reply);