CWE-762: Mismatched Memory Management Routines
The product attempts to return a memory resource to the system, but it calls a release function that is not compatible with the function that was originally used to allocate that resource.
Last updated
Overview
There are multiple ways in which memory management routines can be mismatched, such as:
The memory was allocated on the stack (automatically), but it was deallocated using the memory management routine free() (CWE-590), which is intended for explicitly allocated heap memory.
The memory was allocated explicitly using one set of memory management functions, and deallocated using a different set. For example, memory might be allocated with malloc() in C++ instead of the new operator, and then deallocated with the delete operator.
Real-world CVEs
16 recorded CVEs are caused by CWE-762 (Mismatched Memory Management Routines). The highest-severity and most recent are shown first. 3 new CWE-762 CVEs have been recorded so far in 2026 (5 in 2025).