st/mesa: Fix memory leak in out-of-memory path.

Fixes Coverity resource leak defect.

Signed-off-by: Vinson Lee <vlee@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
This commit is contained in:
Vinson Lee 2011-12-06 00:15:28 -08:00
parent cf79e22509
commit 7b6b5f5102

View file

@ -266,6 +266,7 @@ get_pixel_transfer_program(struct gl_context *ctx, const struct state_key *key)
if (!fp->Base.Instructions) {
_mesa_error(ctx, GL_OUT_OF_MEMORY,
"generating pixel transfer program");
_mesa_free_parameter_list(params);
return NULL;
}