summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEmil Velikov <emil.l.velikov@gmail.com>2014-01-16 17:36:43 +0000
committerEmil Velikov <emil.l.velikov@gmail.com>2014-01-18 19:17:45 +0000
commit66fd5057d3ee1b3a7bce484eb0856b318a8ae4a4 (patch)
tree3101f2cf386397d85757761b840ebf0bf5e871d0
parente1e30f6dfb52b5c59ed551f13316bce0c039de79 (diff)
nv50: drop obsolete check from error path
At 'out_err' the nv50_context has been calloc-ated. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
-rw-r--r--src/gallium/drivers/nouveau/nv50/nv50_context.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/src/gallium/drivers/nouveau/nv50/nv50_context.c b/src/gallium/drivers/nouveau/nv50/nv50_context.c
index 24264d5adbe..10e8b47b38e 100644
--- a/src/gallium/drivers/nouveau/nv50/nv50_context.c
+++ b/src/gallium/drivers/nouveau/nv50/nv50_context.c
@@ -298,15 +298,13 @@ nv50_create(struct pipe_screen *pscreen, void *priv)
return pipe;
out_err:
- if (nv50) {
- if (nv50->bufctx_3d)
- nouveau_bufctx_del(&nv50->bufctx_3d);
- if (nv50->bufctx)
- nouveau_bufctx_del(&nv50->bufctx);
- if (nv50->blit)
- FREE(nv50->blit);
- FREE(nv50);
- }
+ if (nv50->bufctx_3d)
+ nouveau_bufctx_del(&nv50->bufctx_3d);
+ if (nv50->bufctx)
+ nouveau_bufctx_del(&nv50->bufctx);
+ if (nv50->blit)
+ FREE(nv50->blit);
+ FREE(nv50);
return NULL;
}