summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2022-12-07 05:11:47 +1000
committerEric Engestrom <eric@engestrom.ch>2022-12-14 20:47:01 +0000
commit2fbea1fdaa7e0b4cc69e6a89aa00bea890c59c68 (patch)
tree3af00497e18100ca77a2019dfb16c1315dc3751e
parent1fa232af41ac1bc42b830266cd427aeabda3c0f2 (diff)
downloadmesa-2fbea1fdaa7e0b4cc69e6a89aa00bea890c59c68.tar.gz
glx: fix xshm check to init xshm_opcode.
Found and proposed by Ray Strode (halfline) Fixes: 68e89401140d ("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> (cherry picked from commit 57b7102ef96a282128ead4e7a8c03c7fdb53e71a)
-rw-r--r--.pick_status.json2
-rw-r--r--src/glx/drisw_glx.c1
2 files changed, 2 insertions, 1 deletions
diff --git a/.pick_status.json b/.pick_status.json
index b9ab3ff72d8..cfdaa51f59a 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -3181,7 +3181,7 @@
"description": "glx: fix xshm check to init xshm_opcode.",
"nominated": true,
"nomination_type": 1,
- "resolution": 0,
+ "resolution": 1,
"main_sha": null,
"because_sha": "68e89401140d1b3a17052899c54577de3f008b67"
},
diff --git a/src/glx/drisw_glx.c b/src/glx/drisw_glx.c
index 9a99d3e037f..0487d763faa 100644
--- a/src/glx/drisw_glx.c
+++ b/src/glx/drisw_glx.c
@@ -884,6 +884,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);