summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i915/i915_context.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers/dri/i915/i915_context.c')
-rw-r--r--src/mesa/drivers/dri/i915/i915_context.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i915/i915_context.c b/src/mesa/drivers/dri/i915/i915_context.c
index fc4dade21e..eb33b1f1c3 100644
--- a/src/mesa/drivers/dri/i915/i915_context.c
+++ b/src/mesa/drivers/dri/i915/i915_context.c
@@ -72,11 +72,13 @@ static void i915InvalidateState( GLcontext *ctx, GLuint new_state )
*/
{
struct i915_fragment_program *p =
- (struct i915_fragment_program *)ctx->FragmentProgram.Current;
- if (p->nr_params)
+ (struct i915_fragment_program *)ctx->FragmentProgram._Current;
+ if (p && p->nr_params)
p->params_uptodate = 0;
}
+ if (new_state & (_NEW_FOG|_NEW_HINT|_NEW_PROGRAM))
+ i915_update_fog(ctx);
}