btrfs: drop null testing before destroy functions

Cleanup.

kmem_cache_destroy has support NULL argument checking,
so drop the double null testing before calling it.

Signed-off-by: Kinglong Mee <kinglongmee@gmail.com>
Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
Kinglong Mee 2016-01-29 21:36:35 +08:00 committed by David Sterba
parent 89771cc98c
commit 5598e9005a
9 changed files with 17 additions and 34 deletions

View file

@ -43,8 +43,7 @@ int __init btrfs_delayed_inode_init(void)
void btrfs_delayed_inode_exit(void)
{
if (delayed_node_cache)
kmem_cache_destroy(delayed_node_cache);
kmem_cache_destroy(delayed_node_cache);
}
static inline void btrfs_init_delayed_node(