From: jsg Date: Wed, 25 May 2022 12:37:23 +0000 (+0000) Subject: drm/dp/mst: fix a possible memory leak in fetch_monitor_name() X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=ea94e0ea690a57634709b131f0aa4c7a70986947;p=openbsd drm/dp/mst: fix a possible memory leak in fetch_monitor_name() From Hangyu Hua deec86168170d085d4f91445c1f72a900ed02372 in linux 5.15.y/5.15.42 6e03b13cc7d9427c2c77feed1549191015615202 in mainline linux --- diff --git a/sys/dev/pci/drm/drm_dp_mst_topology.c b/sys/dev/pci/drm/drm_dp_mst_topology.c index 433537c18d2..3d7002f372d 100644 --- a/sys/dev/pci/drm/drm_dp_mst_topology.c +++ b/sys/dev/pci/drm/drm_dp_mst_topology.c @@ -4844,6 +4844,7 @@ static void fetch_monitor_name(struct drm_dp_mst_topology_mgr *mgr, mst_edid = drm_dp_mst_get_edid(port->connector, mgr, port); drm_edid_get_monitor_name(mst_edid, name, namelen); + kfree(mst_edid); } /**