CVE-2022-49996

Source
https://cve.org/CVERecord?id=CVE-2022-49996
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-49996.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2022-49996
Downstream
Published
2025-06-18T11:00:56.175Z
Modified
2026-04-02T08:28:07.903321Z
Summary
btrfs: fix possible memory leak in btrfs_get_dev_args_from_path()
Details

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

btrfs: fix possible memory leak in btrfsgetdevargsfrom_path()

In btrfsgetdevargsfrompath(), btrfsgetbdevandsb() can fail if the path is invalid. In this case, btrfsgetdevargsfrompath() returns directly without freeing args->uuid and args->fsid allocated before, which causes memory leak.

To fix these possible leaks, when btrfsgetbdevandsb() fails, btrfsputdevargsfrom_path() is called to clean up the memory.

Database specific
{
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/49xxx/CVE-2022-49996.json",
    "cna_assigner": "Linux"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
321a81835b4aed4f717f89921286f6544ffa8be9
Fixed
5f52402c77013e4a826394b807dd5ea4dc83bd72
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
faa775c41d655a4786e9d53cb075a77bb5a75f66
Fixed
4b124ad87244cd7f0883c5eaa38d2326b2154cad
Fixed
9ea0106a7a3d8116860712e3f17cd52ce99f6707

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-49996.json"