CVE-2022-50474

MEDIUM

Linux Kernel < 4.9.337 - Memory Leak

Title source: rule

Description

In the Linux kernel, the following vulnerability has been resolved: macintosh: fix possible memory leak in macio_add_one_device() Afer commit 1fa5ae857bb1 ("driver core: get rid of struct device's bus_id string array"), the name of device is allocated dynamically. It needs to be freed when of_device_register() fails. Call put_device() to give up the reference that's taken in device_initialize(), so that it can be freed in kobject_cleanup() when the refcount hits 0. macio device is freed in macio_release_dev(), so the kfree() can be removed.

Scores

CVSS v3 5.5
EPSS 0.0001
EPSS Percentile 1.1%
Attack Vector LOCAL
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Classification

CWE
CWE-401
Status published

Affected Products (9)

linux/linux_kernel < 4.9.337
linux/Kernel < 4.9.337linux
linux/Kernel < 4.14.303linux
linux/Kernel < 4.19.270linux
linux/Kernel < 5.4.229linux
linux/Kernel < 5.10.163linux
linux/Kernel < 5.15.86linux
linux/Kernel < 6.0.16linux
linux/Kernel < 6.1.2linux

Timeline

Published Oct 04, 2025
Tracked Since Feb 18, 2026