KindDragon/vld

VLD 2.5.1 report false positive on Visual Studio 2017, MFC, Window 10

kvcuong opened this issue · 2 comments

We have a possible false positive detection of memory leaks on window 10, vs 2017, MFC:

---------- Block 186011 at 0x0000000070C00B50: 512 bytes ----------
Leak Hash: 0x14098C6C, Count: 1, Total 512 bytes
Call Stack (TID 177604):
ucrtbased.dll!malloc_dbg()
mfc140d.dll!0x00007FFF47920001()
mfc140d.dll!0x00007FFF478A0A4B()
mfc140d.dll!0x00007FFF47707DAB()
e:\addoc iim\apuisoft dev\customer.cpp (1801): Addoc64D.exe!CCustomerApp::OnIdle() + 0xE bytes
mfc140d.dll!0x00007FFF478A0F02()
mfc140d.dll!0x00007FFF47708E13()
mfc140d.dll!0x00007FFF47920C44()
d:\agent_work\3\s\src\vctools\vc7libs\ship\atlmfc\src\mfc\appmodul.cpp (26): Addoc64D.exe!WinMain()
d:\agent_work\2\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl (107): Addoc64D.exe!invoke_main()
d:\agent_work\2\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl (288): Addoc64D.exe!__scrt_common_main_seh() + 0x5 bytes
d:\agent_work\2\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl (331): Addoc64D.exe!__scrt_common_main()
d:\agent_work\2\s\src\vctools\crt\vcstartup\src\startup\exe_winmain.cpp (17): Addoc64D.exe!WinMainCRTStartup()
KERNEL32.DLL!BaseThreadInitThunk() + 0x14 bytes
ntdll.dll!RtlUserThreadStart() + 0x21 bytes
Data:
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........
CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD ........ ........

Visual Leak Detector detected 6 memory leaks (1704 bytes).
Largest number used: 7719945 bytes.
Total allocations: 1502986993 bytes.
Visual Leak Detector is now exiting.
Detected memory leaks!

Do you know how to skip/filter such log in the report ?
Thank

I was having a similar issue as well... like only 6 leaks worth of 16 bytes being reported that could not be tracked at all. Now, I'm starting to have crashes inside VLD:
vldcrash

So it randomly worked again. I managed to capture this. Mind you it is in Debug but it still can't pin a method signature:

WARNING: Visual Leak Detector detected memory leaks!
---------- Block 4257 at 0x000000008ED19570: 16 bytes ----------
  Leak Hash: 0x6A373C07, Count: 1, Total 16 bytes
  Call Stack (TID 25640):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF651303E6D()
    HighOmega.exe!0x00007FF6512BC3F3()
    HighOmega.exe!0x00007FF6512C3AFE()
    HighOmega.exe!0x00007FF6511209EE()
    HighOmega.exe!0x00007FF65163632C()
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x11D bytes
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x1FF bytes
    ntdll.dll!LdrShutdownThread() + 0x4DF bytes
    ntdll.dll!LdrInitializeThunk() + 0x484 bytes
    ntdll.dll!LdrInitializeThunk() + 0x63 bytes
    ntdll.dll!LdrInitializeThunk() + 0xE bytes
  Data:
    60 C9 E0 91    6C 02 00 00    00 00 00 00    00 00 00 00     `...l... ........


---------- Block 4282 at 0x000000009438EA20: 16 bytes ----------
  Leak Hash: 0x6A373C07, Count: 1, Total 16 bytes
  Call Stack (TID 25644):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF651303E6D()
    HighOmega.exe!0x00007FF6512BC3F3()
    HighOmega.exe!0x00007FF6512C3AFE()
    HighOmega.exe!0x00007FF6511209EE()
    HighOmega.exe!0x00007FF65163632C()
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x11D bytes
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x1FF bytes
    ntdll.dll!LdrShutdownThread() + 0x4DF bytes
    ntdll.dll!LdrInitializeThunk() + 0x484 bytes
    ntdll.dll!LdrInitializeThunk() + 0x63 bytes
    ntdll.dll!LdrInitializeThunk() + 0xE bytes
  Data:
    90 56 38 94    6C 02 00 00    00 00 00 00    00 00 00 00     .V8.l... ........


---------- Block 4283 at 0x000000009438F740: 16 bytes ----------
  Leak Hash: 0x6A373C07, Count: 1, Total 16 bytes
  Call Stack (TID 25648):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF651303E6D()
    HighOmega.exe!0x00007FF6512BC3F3()
    HighOmega.exe!0x00007FF6512C3AFE()
    HighOmega.exe!0x00007FF6511209EE()
    HighOmega.exe!0x00007FF65163632C()
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x11D bytes
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x1FF bytes
    ntdll.dll!LdrShutdownThread() + 0x4DF bytes
    ntdll.dll!LdrInitializeThunk() + 0x484 bytes
    ntdll.dll!LdrInitializeThunk() + 0x63 bytes
    ntdll.dll!LdrInitializeThunk() + 0xE bytes
  Data:
    E0 28 47 94    6C 02 00 00    00 00 00 00    00 00 00 00     .(G.l... ........


---------- Block 4309 at 0x00000000944DE9A0: 16 bytes ----------
  Leak Hash: 0x6A373C07, Count: 1, Total 16 bytes
  Call Stack (TID 22392):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF651303E6D()
    HighOmega.exe!0x00007FF6512BC3F3()
    HighOmega.exe!0x00007FF6512C3AFE()
    HighOmega.exe!0x00007FF6511209EE()
    HighOmega.exe!0x00007FF65163632C()
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x11D bytes
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x1FF bytes
    ntdll.dll!LdrShutdownThread() + 0x4DF bytes
    ntdll.dll!LdrInitializeThunk() + 0x484 bytes
    ntdll.dll!LdrInitializeThunk() + 0x63 bytes
    ntdll.dll!LdrInitializeThunk() + 0xE bytes
  Data:
    A0 5F F3 96    6C 02 00 00    00 00 00 00    00 00 00 00     ._..l... ........


---------- Block 4310 at 0x00000000944DEDB0: 16 bytes ----------
  Leak Hash: 0x6A373C07, Count: 1, Total 16 bytes
  Call Stack (TID 22804):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF651303E6D()
    HighOmega.exe!0x00007FF6512BC3F3()
    HighOmega.exe!0x00007FF6512C3AFE()
    HighOmega.exe!0x00007FF6511209EE()
    HighOmega.exe!0x00007FF65163632C()
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x11D bytes
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x1FF bytes
    ntdll.dll!LdrShutdownThread() + 0x4DF bytes
    ntdll.dll!LdrInitializeThunk() + 0x484 bytes
    ntdll.dll!LdrInitializeThunk() + 0x63 bytes
    ntdll.dll!LdrInitializeThunk() + 0xE bytes
  Data:
    80 9D F3 96    6C 02 00 00    00 00 00 00    00 00 00 00     ....l... ........


---------- Block 4311 at 0x00000000944DEE50: 16 bytes ----------
  Leak Hash: 0x6A373C07, Count: 1, Total 16 bytes
  Call Stack (TID 7032):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF651303E6D()
    HighOmega.exe!0x00007FF6512BC3F3()
    HighOmega.exe!0x00007FF6512C3AFE()
    HighOmega.exe!0x00007FF6511209EE()
    HighOmega.exe!0x00007FF65163632C()
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x11D bytes
    ntdll.dll!RtlActivateActivationContextUnsafeFast() + 0x1FF bytes
    ntdll.dll!LdrShutdownThread() + 0x4DF bytes
    ntdll.dll!LdrInitializeThunk() + 0x484 bytes
    ntdll.dll!LdrInitializeThunk() + 0x63 bytes
    ntdll.dll!LdrInitializeThunk() + 0xE bytes
  Data:
    70 45 F4 96    6C 02 00 00    00 00 00 00    00 00 00 00     pE..l... ........


---------- Block 427558 at 0x0000000097697FF0: 16 bytes ----------
  Leak Hash: 0x4CA7E509, Count: 1, Total 16 bytes
  Call Stack (TID 26344):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF65130326D()
    HighOmega.exe!0x00007FF6512BBEF3()
    HighOmega.exe!0x00007FF6512C345E()
    HighOmega.exe!0x00007FF6512C6C89()
    HighOmega.exe!0x00007FF6513B0CAC()
    HighOmega.exe!0x00007FF65143AB81()
    HighOmega.exe!0x00007FF65142E02A()
    HighOmega.exe!0x00007FF6514327F3()
    HighOmega.exe!0x00007FF65156AB16()
    HighOmega.exe!0x00007FF6512546AF()
    HighOmega.exe!0x00007FF651636E24()
    HighOmega.exe!0x00007FF651636D0E()
    HighOmega.exe!0x00007FF651636BCE()
    HighOmega.exe!0x00007FF651636EB9()
    KERNEL32.DLL!BaseThreadInitThunk() + 0x14 bytes
    ntdll.dll!RtlUserThreadStart() + 0x21 bytes
  Data:
    B8 5C C4 97    6C 02 00 00    00 00 00 00    00 00 00 00     .\..l... ........


---------- Block 427560 at 0x0000000097698900: 16 bytes ----------
  Leak Hash: 0x87479EF4, Count: 1, Total 16 bytes
  Call Stack (TID 26344):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF6513063ED()
    HighOmega.exe!0x00007FF6512BD2F3()
    HighOmega.exe!0x00007FF6512C518E()
    HighOmega.exe!0x00007FF6513B0CF8()
    HighOmega.exe!0x00007FF65143AB81()
    HighOmega.exe!0x00007FF65142E02A()
    HighOmega.exe!0x00007FF6514327F3()
    HighOmega.exe!0x00007FF65156AB16()
    HighOmega.exe!0x00007FF6512546AF()
    HighOmega.exe!0x00007FF651636E24()
    HighOmega.exe!0x00007FF651636D0E()
    HighOmega.exe!0x00007FF651636BCE()
    HighOmega.exe!0x00007FF651636EB9()
    KERNEL32.DLL!BaseThreadInitThunk() + 0x14 bytes
    ntdll.dll!RtlUserThreadStart() + 0x21 bytes
  Data:
    70 5D C4 97    6C 02 00 00    00 00 00 00    00 00 00 00     p]..l... ........


---------- Block 427559 at 0x0000000097698C20: 16 bytes ----------
  Leak Hash: 0x56635DBC, Count: 1, Total 16 bytes
  Call Stack (TID 26344):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65114BE42()
    HighOmega.exe!0x00007FF651137037()
    HighOmega.exe!0x00007FF6511584EF()
    HighOmega.exe!0x00007FF65130656D()
    HighOmega.exe!0x00007FF6512BD393()
    HighOmega.exe!0x00007FF6512C539E()
    HighOmega.exe!0x00007FF6513B0CE2()
    HighOmega.exe!0x00007FF65143AB81()
    HighOmega.exe!0x00007FF65142E02A()
    HighOmega.exe!0x00007FF6514327F3()
    HighOmega.exe!0x00007FF65156AB16()
    HighOmega.exe!0x00007FF6512546AF()
    HighOmega.exe!0x00007FF651636E24()
    HighOmega.exe!0x00007FF651636D0E()
    HighOmega.exe!0x00007FF651636BCE()
    HighOmega.exe!0x00007FF651636EB9()
    KERNEL32.DLL!BaseThreadInitThunk() + 0x14 bytes
    ntdll.dll!RtlUserThreadStart() + 0x21 bytes
  Data:
    50 5D C4 97    6C 02 00 00    00 00 00 00    00 00 00 00     P]..l... ........


---------- Block 427557 at 0x0000000097C45C90: 344 bytes ----------
  Leak Hash: 0x0637B18A, Count: 1, Total 344 bytes
  Call Stack (TID 26344):
    ucrtbased.dll!malloc()
    HighOmega.exe!0x00007FF651633D63()
    HighOmega.exe!0x00007FF65143AAC9()
    HighOmega.exe!0x00007FF65142E02A()
    HighOmega.exe!0x00007FF6514327F3()
    HighOmega.exe!0x00007FF65156AB16()
    HighOmega.exe!0x00007FF6512546AF()
    HighOmega.exe!0x00007FF651636E24()
    HighOmega.exe!0x00007FF651636D0E()
    HighOmega.exe!0x00007FF651636BCE()
    HighOmega.exe!0x00007FF651636EB9()
    KERNEL32.DLL!BaseThreadInitThunk() + 0x14 bytes
    ntdll.dll!RtlUserThreadStart() + 0x21 bytes
  Data:
    08 B1 70 51    F6 7F 00 00    00 00 00 00    00 00 00 00     ..pQ.... ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    F0 7F 69 97    6C 02 00 00     ........ ..i.l...
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    90 C3 C3 51    F6 7F 00 00    00 00 00 00    00 00 00 00     ...Q.... ........
    00 06 34 00    00 00 00 00    00 01 00 00    00 00 00 00     ..4..... ........
    B2 4F AA 82    E2 EF 1A 39    08 00 00 00    00 00 00 00     .O.....9 ........
    F0 71 4B 94    6C 02 00 00    01 01 00 00    10 00 00 00     .qK.l... ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    20 8C 69 97    6C 02 00 00    00 00 00 00    00 00 00 00     ..i.l... ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 89 69 97    6C 02 00 00    00 00 00 00    00 00 00 00     ..i.l... ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........


Visual Leak Detector detected 10 memory leaks (1008 bytes).
Largest number used: 199207799 bytes.
Total allocations: 929819985 bytes.
Visual Leak Detector is now exiting.