[Bug 270040] micphy: memory leak in micphy

From: <bugzilla-noreply_at_freebsd.org>
Date: Wed, 08 Mar 2023 14:54:23 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=270040

            Bug ID: 270040
           Summary: micphy: memory leak in micphy
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: bin
          Assignee: bugs@FreeBSD.org
          Reporter: jiahali@blackberry.com

Created attachment 240667
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=240667&action=edit
Fix memory leak in micphy

The micphy_attach() uses mii_fdt_get_config() to allocates memory for
mii_fdt_phy_config_t *cfg. However, the allocated memory, mii_fdt_phy_config_t
*cfg, is not freed before the micphy_attach() returns. (See
vscphy_fdt_get_config() in vscphy.c for an example)

-- 
You are receiving this mail because:
You are the assignee for the bug.