mirror of
https://github.com/X11Libre/xserver.git
synced 2026-04-14 17:18:09 +00:00
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 <dottedmag@dottedmag.net>
Reviewed-by: Julien Cristau <jcristau@debian.org>
Reviewed-by: Fernando Carrijo <fcarrijo@yahoo.com.br>
Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:
@@ -37,8 +37,7 @@ RRTransformInit (RRTransformPtr transform)
|
||||
void
|
||||
RRTransformFini (RRTransformPtr transform)
|
||||
{
|
||||
if (transform->params)
|
||||
free(transform->params);
|
||||
free(transform->params);
|
||||
}
|
||||
|
||||
Bool
|
||||
@@ -82,8 +81,7 @@ RRTransformSetFilter (RRTransformPtr dst,
|
||||
}
|
||||
else
|
||||
new_params = NULL;
|
||||
if (dst->params)
|
||||
free(dst->params);
|
||||
free(dst->params);
|
||||
dst->filter = filter;
|
||||
dst->params = new_params;
|
||||
dst->nparams = nparams;
|
||||
|
||||
Reference in New Issue
Block a user