st/dri: Use flush function of old context not new
authorJakob Bornecrantz <jakob@vmware.com>
Mon, 26 Apr 2010 13:59:46 +0000 (14:59 +0100)
committerJakob Bornecrantz <jakob@vmware.com>
Tue, 27 Apr 2010 11:17:11 +0000 (12:17 +0100)
src/gallium/state_trackers/dri/common/dri_context.c

index 0e5ab5b51982b6727ae675031a3a5a7c7f75a12b..a144247d0c6b693974bf590573aca9839102a831 100644 (file)
@@ -151,7 +151,7 @@ dri_make_current(__DRIcontext * cPriv,
 
       old_st = stapi->get_current(stapi);
       if (old_st && old_st != ctx->st)
-        ctx->st->flush(old_st, PIPE_FLUSH_RENDER_CACHE, NULL);
+        old_st->flush(old_st, PIPE_FLUSH_RENDER_CACHE, NULL);
 
       ++ctx->bind_count;