Consider this scenario:

  • You develop an application that calls the WNetAddConnection2 function and the WNetCancelConnection2 function. This application enables you to connect and to disconnect the network drive to other computers that have a drive letter.
  • You run this application on a computer that is running Windows Vista or Windows Server 2008.

In this scenario,you find a memory leak in NETAPI32.DLL module. There is about 1KB of memory leak every time that you connect or disconnect. Therefore, system performance decreases gradually over time.

Leave a Reply