Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Memory leak? #173

Closed
pparekh77 opened this issue Jun 20, 2018 · 4 comments
Closed

Memory leak? #173

pparekh77 opened this issue Jun 20, 2018 · 4 comments

Comments

@pparekh77
Copy link

pparekh77 commented Jun 20, 2018

I pulled down the latest sources and then ran example_psdk. Once the app launches, I simply quit. In the Debug Window, I see the following:

Detected memory leaks!
Dumping objects ->
{1837} normal block at 0x0331F3E8, 20 bytes long.
 Data: <  H     lH      > C0 ED 48 10 1C 03 00 00 6C 48 00 00 14 03 00 00 
Object dump complete.
The program '[8336] example_psdk.exe' has exited with code 0 (0x0).

Have you seen this before?

I am on Windows 10 and using Visual Studio 2015.

I initially saw this in the application in which I integrated Winsparkle so I wanted to see if this was happening in the example app too.

@pparekh77
Copy link
Author

Adding some clarification:
This will not happen on the first run.
On the second run, you will need to allow automatic update checks.
Once you do, then when you quit the second time or on subsequent runs of the app, you will see this.

@vslavik
Copy link
Owner

vslavik commented Jun 21, 2018

That "leaks" in wxWidgets code only show up when said code is executed is not terribly surprising.

I lack your confidence that they are actual leaks and not false positive, and that they matter (i.e. are not occurring only once per process lifetime). If you think they are real, then please investigate & debug (here's a helpful tip), understand and submit a PR with a fix — I'll gladly merge your contribution in.

@pparekh77
Copy link
Author

pparekh77 commented Jun 21, 2018

Investigating further, this is what I see:

Detected memory leaks!
Dumping objects ->
{1837} normal block at 0x03666178, 20 bytes long.
 Data: <        h       > C0 ED DD 0F 00 03 00 00 68 07 00 00 F8 02 00 00 
Object dump complete.
WARNING: Visual Leak Detector detected memory leaks!
---------- Block 1904 at 0x03666178: 20 bytes ----------
  Leak Hash: 0xE69E15E0, Count: 1, Total 20 bytes
  Call Stack (TID 1516):
    ntdll.dll!RtlAllocateHeap()
    f:\dd\vctools\crt\vcstartup\src\heap\new_scalar.cpp (19): WinSparkle.dll!operator new() + 0x9 bytes
    c:\winsparkle\src\dll_api.cpp (78): WinSparkle.dll!win_sparkle_init() + 0x7 bytes
    c:\winsparkle\examples\psdk\app_psdk.c (175): example_psdk.exe!WinMain() + 0x8 bytes
    f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl (99): example_psdk.exe!invoke_main()
    f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl (253): example_psdk.exe!__scrt_common_main_seh() + 0x5 bytes
    f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl (296): example_psdk.exe!__scrt_common_main()
    f:\dd\vctools\crt\vcstartup\src\startup\exe_winmain.cpp (17): example_psdk.exe!WinMainCRTStartup()
    KERNEL32.DLL!BaseThreadInitThunk() + 0x24 bytes
    ntdll.dll!RtlGetAppContainerNamedObjectPath() + 0x137 bytes
    ntdll.dll!RtlGetAppContainerNamedObjectPath() + 0x107 bytes
  Data:
    C0 ED DD 0F    00 03 00 00    68 07 00 00    F8 02 00 00     ........ h.......
    FC 02 00 00                                                  ........ ........


Visual Leak Detector detected 1 memory leak (56 bytes).
Largest number used: 80386 bytes.
Total allocations: 276404 bytes.
Visual Leak Detector is now exiting.
The program '[22816] example_psdk.exe' has exited with code 0 (0x0).

@vslavik
Copy link
Owner

vslavik commented Mar 29, 2023

The wxWidgets upgrade in #249 likely addressed this, so closing.

@vslavik vslavik closed this as completed Mar 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants