From 985e710c0d1f4f3bbd18448f04e611bd57ae9100 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Thu, 31 Jan 2013 23:28:41 -0800 Subject: swrast: Fix memory leak. Fixes resource leak defect reported by Coverity. Signed-off-by: Vinson Lee Reviewed-by: Brian Paul --- src/mesa/drivers/dri/swrast/swrast.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/mesa/drivers/dri/swrast/swrast.c b/src/mesa/drivers/dri/swrast/swrast.c index 96382718a8e..b380de3078c 100644 --- a/src/mesa/drivers/dri/swrast/swrast.c +++ b/src/mesa/drivers/dri/swrast/swrast.c @@ -363,6 +363,7 @@ swrast_new_renderbuffer(const struct gl_config *visual, __DRIdrawable *dPriv, xrb->bpp = 8; break; default: + free(xrb); return NULL; } -- cgit v1.2.3