mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-31 14:10:09 +01:00
don't alloc region in xmesa_surface_alloc(), fixes a mem leak
This commit is contained in:
parent
257f0da6a2
commit
ffd37b1fda
1 changed files with 1 additions and 3 deletions
|
|
@ -284,6 +284,7 @@ xmesa_surface_alloc(struct pipe_context *pipe, GLuint pipeFormat)
|
|||
{
|
||||
struct xmesa_surface *xms = CALLOC_STRUCT(xmesa_surface);
|
||||
|
||||
assert(pipe);
|
||||
assert(pipeFormat);
|
||||
|
||||
xms->surface.surface.format = pipeFormat;
|
||||
|
|
@ -293,9 +294,6 @@ xmesa_surface_alloc(struct pipe_context *pipe, GLuint pipeFormat)
|
|||
*/
|
||||
softpipe_init_surface_funcs(&xms->surface);
|
||||
|
||||
assert(pipe);
|
||||
xms->surface.surface.region = pipe->region_alloc(pipe, 1, 1, 1, 0x0);
|
||||
|
||||
return &xms->surface.surface;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue