Re: [patch] fs: Make unload_nls() NULL pointer safe

From: Dave Kleikamp
Date: Mon Aug 17 2009 - 08:40:25 EST


On Sun, 2009-08-16 at 21:05 +0000, Thomas Gleixner wrote:
> plain text document attachment (unload_nls.patch)
> Most call sites of unload_nls() do:
> if (nls)
> unload_nls(nls);
>
> Check the pointer inside unload_nls() like we do in kfree() and
> simplify the call sites.
>
> Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
> Cc: Steve French <sfrench@xxxxxxxxxx>
> Cc: OGAWA Hirofumi <hirofumi@xxxxxxxxxxxxxxxxxx>
> Cc: Roman Zippel <zippel@xxxxxxxxxxxxxx>

Acked-by: Dave Kleikamp <shaggy@xxxxxxxxxxxxxxxxxx>

> Cc: Petr Vandrovec <vandrove@xxxxxxxxxx>
> Cc: Anton Altaparmakov <aia21@xxxxxxxxxx>
>
> ---
> fs/befs/linuxvfs.c | 7 +------
> fs/cifs/cifsfs.c | 3 +--
> fs/fat/inode.c | 16 ++++------------
> fs/hfs/mdb.c | 6 ++----
> fs/hfsplus/super.c | 6 ++----
> fs/isofs/inode.c | 8 ++------
> fs/jfs/super.c | 9 +++------
> fs/ncpfs/inode.c | 12 ++----------
> fs/ncpfs/ioctl.c | 6 ++----
> fs/nls/nls_base.c | 3 ++-
> fs/ntfs/super.c | 10 ++++------
> fs/smbfs/inode.c | 10 ++--------
> 12 files changed, 27 insertions(+), 69 deletions(-)
--
David Kleikamp
IBM Linux Technology Center

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/