]> git.baikalelectronics.ru Git - kernel.git/commit
rbd: drop null test before destroy functions
authorJulia Lawall <Julia.Lawall@lip6.fr>
Sun, 13 Sep 2015 12:15:26 +0000 (14:15 +0200)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 2 Nov 2015 22:36:47 +0000 (23:36 +0100)
commit594feb0f37393311d1978045b09fb17cd71065be
treef7bb252e25cb3da43f0f3cb611d0aba2d94b3de5
parent9d3ff5a7c8fe5f44fd48e22d9c3aa180e92e1bac
rbd: drop null test before destroy functions

Remove unneeded NULL test.

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

// <smpl>
@@ expression x; @@
-if (x != NULL) {
  \(kmem_cache_destroy\|mempool_destroy\|dma_pool_destroy\)(x);
  x = NULL;
-}
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
drivers/block/rbd.c