Dangling Pointer
Reports the usages of the pointers that refer to the memory already deleted by the delete
operator or the free(void* ptr)
function.
Example:
void process() {
for(node *pt = head; pt != nullptr; pt = pt->next) {
delete pt;
}
}
Inspection Details | |
---|---|
Available in: | AppCode 2023.3, CLion 2023.3 |
Plugin: | CLion, 2023.3 |
Last modified: 13 July 2023