Files
linux-stable-mirror/fs
Li LingfengandGreg Kroah-Hartman 2a4a997adb nfs: fix memory leak in error path of nfs4_do_reclaim
commit 8f6a7c9467 upstream.

Commit c77e22834a ("NFSv4: Fix a potential sleep while atomic in
nfs4_do_reclaim()") separate out the freeing of the state owners from
nfs4_purge_state_owners() and finish it outside the rcu lock.
However, the error path is omitted. As a result, the state owners in
"freeme" will not be released.
Fix it by adding freeing in the error path.

Fixes: c77e22834a ("NFSv4: Fix a potential sleep while atomic in nfs4_do_reclaim()")
Signed-off-by: Li Lingfeng <lilingfeng3@huawei.com>
Cc: stable@vger.kernel.org # v5.3+
Signed-off-by: Anna Schumaker <anna.schumaker@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-10-04 16:29:56 +02:00
..
2024-08-19 06:04:25 +02:00
2024-09-08 07:54:46 +02:00
2024-08-03 08:54:22 +02:00
2024-08-29 17:33:33 +02:00
2024-08-19 06:04:25 +02:00
2024-10-04 16:29:48 +02:00
2024-02-23 09:25:13 +01:00
2024-07-05 09:34:04 +02:00
2024-08-19 06:04:25 +02:00