evas: Avoid crash when there's no GL implementation
authorMike McCormack <mikem@ring3k.org>
Sat, 31 Dec 2011 23:07:22 +0000 (23:07 +0000)
committerMike McCormack <mikem@ring3k.org>
Sat, 31 Dec 2011 23:07:22 +0000 (23:07 +0000)
Signed-off-by: Mike McCormack <mikem@ring3k.org>
SVN revision: 66708

legacy/evas/src/lib/canvas/evas_gl.c

index 47bb583..08edbc4 100644 (file)
@@ -135,6 +135,12 @@ evas_gl_context_create(Evas_GL *evas_gl, Evas_GL_Context *share_ctx)
         return NULL;
      }
 
+   if (!evas_gl->evas->engine.func->gl_context_create)
+     {
+        ERR("GL engine not available\n");
+        return NULL;
+     }
+
    // Call engine->gl_create_context
    if (share_ctx)
      {