From 0a4d8cbdcd7b25313fb29ccdb498044af95f7de6 Mon Sep 17 00:00:00 2001 From: Mikhail Gusarov Date: Sun, 6 Jun 2010 15:28:30 +0700 Subject: Remove more superfluous if(p) checks around free(p) This patch has been generated by the following Coccinelle semantic patch: @@ expression E; @@ -if(E) { free(E); } +free(E); Signed-off-by: Mikhail Gusarov Reviewed-by: Julien Cristau Reviewed-by: Fernando Carrijo Reviewed-by: Matt Turner --- glx/glxext.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'glx/glxext.c') diff --git a/glx/glxext.c b/glx/glxext.c index 4d02b4778..e203156e4 100644 --- a/glx/glxext.c +++ b/glx/glxext.c @@ -205,8 +205,8 @@ GLboolean __glXFreeContext(__GLXcontext *cx) { if (cx->idExists || cx->isCurrent) return GL_FALSE; - if (cx->feedbackBuf) free(cx->feedbackBuf); - if (cx->selectBuf) free(cx->selectBuf); + free(cx->feedbackBuf); + free(cx->selectBuf); if (cx == __glXLastContext) { __glXFlushContextCache(); } @@ -323,10 +323,10 @@ glxClientCallback (CallbackListPtr *list, } } - if (cl->returnBuf) free(cl->returnBuf); - if (cl->largeCmdBuf) free(cl->largeCmdBuf); - if (cl->currentContexts) free(cl->currentContexts); - if (cl->GLClientextensions) free(cl->GLClientextensions); + free(cl->returnBuf); + free(cl->largeCmdBuf); + free(cl->currentContexts); + free(cl->GLClientextensions); break; default: -- cgit v1.2.3