summaryrefslogtreecommitdiffstats
path: root/src/mesa/program/nvvertparse.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/program/nvvertparse.c')
-rw-r--r--src/mesa/program/nvvertparse.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/mesa/program/nvvertparse.c b/src/mesa/program/nvvertparse.c
index b33056a3990..6272c2f7fee 100644
--- a/src/mesa/program/nvvertparse.c
+++ b/src/mesa/program/nvvertparse.c
@@ -1382,14 +1382,10 @@ _mesa_parse_nv_vertex_program(struct gl_context *ctx, GLenum dstTarget,
/* install the program */
program->Base.Target = target;
- if (program->Base.String) {
- free(program->Base.String);
- }
+ free(program->Base.String);
program->Base.String = programString;
program->Base.Format = GL_PROGRAM_FORMAT_ASCII_ARB;
- if (program->Base.Instructions) {
- free(program->Base.Instructions);
- }
+ free(program->Base.Instructions);
program->Base.Instructions = newInst;
program->Base.InputsRead = parseState.inputsRead;
if (parseState.isPositionInvariant)