diff options
author | Brian Paul <[email protected]> | 2006-11-23 15:58:30 +0000 |
---|---|---|
committer | Brian Paul <[email protected]> | 2006-11-23 15:58:30 +0000 |
commit | 308b85f29f191409e42935a3ccd5c502bdf70608 (patch) | |
tree | 03de268e41f9265113667586ca8ba8b85e9a0891 /src/mesa/shader/program.c | |
parent | 897b9c5cb2e9d4d155b07dc6cf25de648fb3bf20 (diff) |
fix several program-related bugs (bug 9136)
Diffstat (limited to 'src/mesa/shader/program.c')
-rw-r--r-- | src/mesa/shader/program.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/shader/program.c b/src/mesa/shader/program.c index 789d36eba02..ddfad47b894 100644 --- a/src/mesa/shader/program.c +++ b/src/mesa/shader/program.c @@ -207,6 +207,7 @@ _mesa_init_program_struct( GLcontext *ctx, struct gl_program *prog, prog->Target = target; prog->Resident = GL_TRUE; prog->RefCount = 1; + prog->Format = GL_PROGRAM_FORMAT_ASCII_ARB; } return prog; @@ -284,6 +285,9 @@ _mesa_delete_program(GLcontext *ctx, struct gl_program *prog) (void) ctx; ASSERT(prog); + if (prog == &_mesa_DummyProgram) + return; + if (prog->String) _mesa_free(prog->String); |