mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-10 12:57:06 +09:00
xfs: use kmem_free to free return value of kmem_zalloc
commit 6c370590cf upstream.
In function xfs_test_remount_options(), kfree() is used to free memory
allocated by kmem_zalloc(). But it is better to use kmem_free().
Signed-off-by: Pan Bian <bianpan2016@163.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
772003c6a4
commit
81cb6f1a2a
@@ -1214,7 +1214,7 @@ xfs_test_remount_options(
|
||||
tmp_mp->m_super = sb;
|
||||
error = xfs_parseargs(tmp_mp, options);
|
||||
xfs_free_fsname(tmp_mp);
|
||||
kfree(tmp_mp);
|
||||
kmem_free(tmp_mp);
|
||||
|
||||
return error;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user