[PATCH] get rid of redundant checks for NULL before kfree() in fs/jffs/
Jesper Juhl <[email protected]> Fri, 25 Mar 2005 23:18:16 +0100 (CET)
| Newsgroups | gmane.linux.kernel,gmane.linux.file-systems.jffs |
|---|---|
| Message-ID | <[email protected]> |
There's no need to check for NULL before calling kfree(). Signed-off-by: Jesper Juhl <[email protected]> --- linux-2.6.12-rc1-mm3-orig/fs/jffs/intrep.c 2005-03-21 23:12:41.000000000 +0100 +++ linux-2.6.12-rc1-mm3/fs/jffs/intrep.c 2005-03-25 22:47:29.000000000 +0100 @@ -1693,9 +1693,7 @@ jffs_find_child(struct jffs_file *dir, c } printk("jffs_find_child(): Didn't find the file \"%s\".\n", (copy ? copy : "")); - if (copy) { - kfree(copy); - } + kfree(copy); }); return f;