No, you do not leak.
If you mix dll models (static, dynamic), you can get a memory error if you allocate memory in the dll that you produce in another (or free in exe)
This means that the heap created by the statically linked CRT is not the same heap as the other CRT DLL.
If you contacted the dynamic version of CRT, you will have a leak, since the heap will be used among all dynamically linked CRTs. This means that you should always design applications to use dynamic CRTs or ensure that you never control memory across the dll border (i.e. if you allocate memory in the dll, always provide a program to free it in the same DLL)
gbjbaanb
source share