diff options
author | Vinson Lee <[email protected]> | 2012-11-07 23:13:38 -0800 |
---|---|---|
committer | Vinson Lee <[email protected]> | 2012-11-08 21:28:15 -0800 |
commit | 2aa783318dd40d9ba82b541c1af144f3103b0888 (patch) | |
tree | 0cae7d05fdd6a0a9911fb4b2945cafe17126a152 /src/gallium/drivers | |
parent | 2c8f08813243b867801008a157c44ce9debdcfd2 (diff) |
svga: Fix memory leak in svga_buffer_transfer_map.
Fixes resource leak defect reported by Coverity.
Signed-off-by: Vinson Lee <[email protected]>
Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r-- | src/gallium/drivers/svga/svga_resource_buffer.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gallium/drivers/svga/svga_resource_buffer.c b/src/gallium/drivers/svga/svga_resource_buffer.c index 87a4a9b7a82..3aa6644a4a3 100644 --- a/src/gallium/drivers/svga/svga_resource_buffer.c +++ b/src/gallium/drivers/svga/svga_resource_buffer.c @@ -206,6 +206,8 @@ svga_buffer_transfer_map(struct pipe_context *pipe, ++sbuf->map.count; map += transfer->box.x; *ptransfer = transfer; + } else { + FREE(transfer); } return map; |