staging: lustre: ptlrpc: sec_plain: remove unneeded null test before free
authorJulia Lawall <Julia.Lawall@lip6.fr>
Fri, 1 May 2015 19:37:48 +0000 (21:37 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 8 May 2015 07:23:56 +0000 (09:23 +0200)
commit76372381dd6f5ed4b53fae0c00666e25680e21c5
treeb0b4e1c37a9237948f8bf4f548e87f44a6ebd7be
parent848e90c332f500344a248e3dd673e61b8ad58ce0
staging: lustre: ptlrpc: sec_plain: remove unneeded null test before free

Kfree can cope with a null argument, so drop null tests.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@ expression ptr; @@

- if (ptr != NULL)
  kfree(ptr);
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/ptlrpc/sec_plain.c