summaryrefslogtreecommitdiff
path: root/lib/mesa/src/gallium/winsys
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2019-02-19 03:49:33 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2019-02-19 03:49:33 +0000
commitf91dd1f4590cab6e33b22615af06f38c0698d485 (patch)
tree231197d157923574ee8c0faccf46ab77d1ca699c /lib/mesa/src/gallium/winsys
parent6601b8849bc74eba7faea2956db89976722e3391 (diff)
Import Mesa 18.3.4
Diffstat (limited to 'lib/mesa/src/gallium/winsys')
-rw-r--r--lib/mesa/src/gallium/winsys/sw/xlib/xlib_sw_winsys.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/mesa/src/gallium/winsys/sw/xlib/xlib_sw_winsys.c b/lib/mesa/src/gallium/winsys/sw/xlib/xlib_sw_winsys.c
index 875313910..a4c1d5045 100644
--- a/lib/mesa/src/gallium/winsys/sw/xlib/xlib_sw_winsys.c
+++ b/lib/mesa/src/gallium/winsys/sw/xlib/xlib_sw_winsys.c
@@ -396,6 +396,7 @@ xlib_displaytarget_create(struct sw_winsys *winsys,
{
struct xlib_displaytarget *xlib_dt;
unsigned nblocksy, size;
+ int ignore;
xlib_dt = CALLOC_STRUCT(xlib_displaytarget);
if (!xlib_dt)
@@ -410,7 +411,8 @@ xlib_displaytarget_create(struct sw_winsys *winsys,
xlib_dt->stride = align(util_format_get_stride(format, width), alignment);
size = xlib_dt->stride * nblocksy;
- if (!debug_get_option_xlib_no_shm()) {
+ if (!debug_get_option_xlib_no_shm() &&
+ XQueryExtension(xlib_dt->display, "MIT-SHM", &ignore, &ignore, &ignore)) {
xlib_dt->data = alloc_shm(xlib_dt, size);
if (xlib_dt->data) {
xlib_dt->shm = True;