To accommodate SimCity (and I strongly suspect other programs), Windows would detect it and run a special version of the deallocator that allowed its form of use after freeing (see e.g. http://www.joelonsoftware.com/articles/APIWar.html).
I've been using C since ~ 1980 (sic), loathe C++, and, yeah, I'm going to investigate Rust in due course.
I've been using C since ~ 1980 (sic), loathe C++, and, yeah, I'm going to investigate Rust in due course.