tdfx: condition always evaluates to false in SetupDoubleTexEnvVoodoo3()
[mesa.git] / src / mesa / shader / arbprogparse.c
index 05ee4f563eb7a2fe8b40bb8c1ab76e03a882da98..dd732b6666bc07afa011c52929d68fca17f15b6a 100644 (file)
@@ -87,6 +87,9 @@ _mesa_parse_arb_fragment_program(GLcontext* ctx, GLenum target,
       return;
    }
 
+   if (program->Base.String != NULL)
+      _mesa_free(program->Base.String);
+
    /* Copy the relevant contents of the arb_program struct into the
     * fragment_program struct.
     */
@@ -178,6 +181,9 @@ _mesa_parse_arb_vertex_program(GLcontext *ctx, GLenum target,
       return;
    }
 
+   if (program->Base.String != NULL)
+      _mesa_free(program->Base.String);
+
    /* Copy the relevant contents of the arb_program struct into the 
     * vertex_program struct.
     */