summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2010-01-21 17:39:01 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2010-02-22 09:53:56 +0000
commit5abee283d310a70efa4c713707f06624d5462322 (patch)
tree40724d21cea0c620fa58d93afe0acc9a1c9b22d0 /src/mesa
parentb14548ea32000459f4f0c4b49f3fa11d1ee9c003 (diff)
intel: Check that we have a bufmgr or bail out when initializing the context.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/intel/intel_context.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_context.c b/src/mesa/drivers/dri/intel/intel_context.c
index ced8d5aebe..3c36c3f4c8 100644
--- a/src/mesa/drivers/dri/intel/intel_context.c
+++ b/src/mesa/drivers/dri/intel/intel_context.c
@@ -594,6 +594,10 @@ intelInitContext(struct intel_context *intel,
struct intel_screen *intelScreen = sPriv->private;
int bo_reuse_mode;
+ /* we can't do anything without a connection to the device */
+ if (intelScreen->bufmgr == NULL)
+ return GL_FALSE;
+
if (!_mesa_initialize_context(&intel->ctx, mesaVis, shareCtx,
functions, (void *) intel)) {
printf("%s: failed to init mesa context\n", __FUNCTION__);