thread count is increasing every time we unload flash from process space a thread is left over
Application hosts flash.ocx in a STA environment to renderer flash content within the application. Periodically the Hosting application will execute “cofreeunusedlibraries” to free up the memory by unloading unused libaires. When the cofreeunusedlibraries is executed flalsh.ocx is unload from the process space (because the reference counts is zero) which is a correct behavior. However, we see a side effect that thread count is increasing every time we unload flash from process space a thread is left over.
After analyzing user mode process dump we see there are many instance of the below threads.
469bfd7c 77416a04 ntdll!KiFastSystemCallRet
469bfd80 756969dc ntdll!ZwWaitForMultipleObjects+0xc
469bfe1c 7597bc8e KERNELBASE!WaitForMultipleObjectsEx+0x100
469bfe64 7597bcfc kernel32!WaitForMultipleObjectsExImplementation+0xe0
469bfe80 5b90e1d8 kernel32!WaitForMultipleObjects+0x18
WARNING: Stack unwind information not available. Following frames may be wrong.
469bfeb4 5b8142a1 Flash!DllUnregisterServer+0x52196
469bff00 5b90e28d Flash+0x1442a1
469bff74 5b90e3bc Flash!DllUnregisterServer+0x5224b
469bff94 774337f5 Flash!DllUnregisterServer+0x5237a
469bffd4 774337c8 ntdll!__RtlUserThreadStart+0x70
469bffec 00000000 ntdll!_RtlUserThreadStart+0x1b
We want to understand whether this is a existence bug ?
