Reverse Engineering
Detecting a Heap Memory Leak in a Process 힙 메모리 누수 확인
J-sean
2023. 5. 8. 22:36
반응형
동적으로 할당한 힙 메모리의 누수를 탐지해 보자.
/i: Image file settings
+ust: Creates a run-time stack trace database in the address space of a particular process (image file mode) or all processes (system-wide). (Create user mode stack trace database flag)
-p: specify the PID
-f: specify the name and location of the output file for the heap dump
8회의 동작으로 320바이트의 메모리가 할당되고 해제되지 않았음을 확인 할 수 있다. 메모리 누수로 의심되는 코드는 CLabAppDlg 클래스의 OnMemoryleakBtn 함수다.
반응형