Check for NULL in intelSwapBuffers()

This commit is contained in:
Thomas Hellström 2006-09-18 14:18:14 +00:00
parent 8c58a32360
commit cd3c9febda

View file

@ -697,7 +697,12 @@ intelSwapBuffers(__DRIdrawablePrivate * dPriv)
{
if (dPriv->driContextPriv && dPriv->driContextPriv->driverPrivate) {
GET_CURRENT_CONTEXT(ctx);
struct intel_context *intel = intel_context(ctx);
struct intel_context *intel;
if (ctx == NULL)
return;
intel = intel_context(ctx);
if (ctx->Visual.doubleBufferMode) {
intelScreenPrivate *screen = intel->intelScreen;