linker: Fix memory leak in count_uniform_size::visit_field.

Fixes a Coverity resource leak defect.

NOTE: This is a candidate for the 8.0 branch.

Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
(cherry picked from commit 4123d0b321)
This commit is contained in:
Vinson Lee 2012-03-30 23:36:45 -07:00 committed by Ian Romanick
parent b4693383bf
commit 8537544be9

View file

@ -174,8 +174,7 @@ private:
if (this->map->get(id, name))
return;
char *key = strdup(name);
this->map->put(this->num_active_uniforms, key);
this->map->put(this->num_active_uniforms, name);
/* Each leaf uniform occupies one entry in the list of active
* uniforms.