I used to believe it does for certain but... I can't find it explicitly stated.man 3 exit and man 2 _exit verbosely specify the effects of process termination, but don't mention memory leaks.
A couple of months ago I asked this question where I asked why there was a memory leak. Apparently, I forgot a virtual destructor.
I have this code:When program starts memory consumption is about ~600kb, and when it ends ~1700kb. Is it memory leak or what?
I'm using valgrind to check for memory leaks. Unfortunately I get a Leak_DefinitelyLost warning.Attached is a simplified version of my code that reproduces the error:
The following codeCompiled and run width clang in macOS:Got resultCompiled and run in Visual Studio 2015 Update 3: