CVE-2022-49996

btrfs: fix possible memory leak in btrfs_get_dev_args_from_path()

published June 18, 2025

CVSS
—
EPSS
0%
Percentile
14.6
In the wild
Unconfirmed
What it is

In the Linux kernel, the following vulnerability has been resolved:

btrfs: fix possible memory leak in btrfs_get_dev_args_from_path()

In btrfs_get_dev_args_from_path(), btrfs_get_bdev_and_sb() can fail if

the path is invalid. In this case, btrfs_get_dev_args_from_path()

returns directly without freeing args->uuid and args->fsid allocated

before, which causes memory leak.

To fix these possible leaks, when btrfs_get_bdev_and_sb() fails,

btrfs_put_dev_args_from_path() is called to clean up the memory.

The record
Technical detail
CVSS
Not scored
CVSS v4.0
Not supplied
EPSS
0.00243 · 14.6th percentile
Published
2025-06-18T11:00Z
EPSS history
Timeline
  • 18 JUN 11:00Z
    btrfs: fix possible memory leak in btrfs_get_dev_args_from_path()
    cvelistv5