Mesa (master): r200: move driContextSetFlags(ctx) call after ctx var is initialized

Brian Paul brianp at kemper.freedesktop.org
Sat Feb 1 00:09:57 UTC 2014


Module: Mesa
Branch: master
Commit: 2d6d69bab6c74d92514b81a68c6c8b1dc428182a
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=2d6d69bab6c74d92514b81a68c6c8b1dc428182a

Author: Brian Paul <brianp at vmware.com>
Date:   Fri Jan 31 17:09:44 2014 -0700

r200: move driContextSetFlags(ctx) call after ctx var is initialized

Otherwise, ctx was a garbage value.

CC: "10.0" <mesa-stable at lists.freedesktop.org>
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>

---

 src/mesa/drivers/dri/r200/r200_context.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/mesa/drivers/dri/r200/r200_context.c b/src/mesa/drivers/dri/r200/r200_context.c
index 637a263..0043090 100644
--- a/src/mesa/drivers/dri/r200/r200_context.c
+++ b/src/mesa/drivers/dri/r200/r200_context.c
@@ -279,12 +279,13 @@ GLboolean r200CreateContext( gl_api api,
      return GL_FALSE;
    }
 
-   driContextSetFlags(ctx, flags);
-
    rmesa->radeon.swtcl.RenderIndex = ~0;
    rmesa->radeon.hw.all_dirty = 1;
 
    ctx = &rmesa->radeon.glCtx;
+
+   driContextSetFlags(ctx, flags);
+
    /* Initialize the software rasterizer and helper modules.
     */
    _swrast_CreateContext( ctx );




More information about the mesa-commit mailing list