From: Al Viro Date: Wed, 11 Feb 2026 20:11:28 +0000 (-0500) Subject: udf: fix nls leak on udf_fill_super() failure X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=462bdd08fbdf41db223c6117d907c8fd68d666ea;p=thirdparty%2Flinux.git udf: fix nls leak on udf_fill_super() failure On all failure exits that go to error_out there we have already moved the nls reference from uopt->nls_map to sbi->s_nls_map, leaving NULL behind. Fixes: c4e89cc674ac ("udf: convert to new mount API") Acked-by: Jan Kara Signed-off-by: Al Viro --- diff --git a/fs/udf/super.c b/fs/udf/super.c index b2f168b0a0d18..97a51c64ad48d 100644 --- a/fs/udf/super.c +++ b/fs/udf/super.c @@ -2320,7 +2320,7 @@ static int udf_fill_super(struct super_block *sb, struct fs_context *fc) error_out: iput(sbi->s_vat_inode); - unload_nls(uopt->nls_map); + unload_nls(sbi->s_nls_map); if (lvid_open) udf_close_lvid(sb); brelse(sbi->s_lvid_bh);