From: Brian Date: Thu, 16 Aug 2007 23:30:38 +0000 (-0600) Subject: check for null swrast (pipe work-around) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9ba4311e71f510797e1b446ab7dc6b6d4dc55dd5;p=mesa.git check for null swrast (pipe work-around) --- diff --git a/src/mesa/swrast/s_context.c b/src/mesa/swrast/s_context.c index 39569256514..f43fa61f8a3 100644 --- a/src/mesa/swrast/s_context.c +++ b/src/mesa/swrast/s_context.c @@ -524,6 +524,9 @@ _swrast_update_texture_samplers(GLcontext *ctx) SWcontext *swrast = SWRAST_CONTEXT(ctx); GLuint u; + if (!swrast) + return; /* pipe hack */ + for (u = 0; u < ctx->Const.MaxTextureImageUnits; u++) { const struct gl_texture_object *tObj = ctx->Texture.Unit[u]._Current; /* Note: If tObj is NULL, the sample function will be a simple