summaryrefslogtreecommitdiff
path: root/fs/nls
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nls')
-rw-r--r--fs/nls/nls_base.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/nls/nls_base.c b/fs/nls/nls_base.c
index b25c218671b3..44a88a9fa2c8 100644
--- a/fs/nls/nls_base.c
+++ b/fs/nls/nls_base.c
@@ -270,7 +270,8 @@ struct nls_table *load_nls(char *charset)
void unload_nls(struct nls_table *nls)
{
- module_put(nls->owner);
+ if (nls)
+ module_put(nls->owner);
}
static const wchar_t charset2uni[256] = {