CComClassFactorySingleton::CreateInstance - it looks like a deadlock
bug here:
===
if (m_hrCreate == S_OK && m_spObj == NULL)
{
Lock();
// Did another thread got here first
if (m_hrCreate == S_OK && m_spObj == NULL) // ***
{
// Skipped
Unlock();
}
}
===
if expression in line *** evaluates as false, Unlock will never be
called for a locked for a locked critical section and the calling
thread will freeze.
Roman
This bug is fixed in ATL8 (as shipped with VC8 aka VC.NET 2005). As an
aside, you can report bugs to MS here:
http://connect.microsoft.com/VisualStudio
--
With best wishes,
Igor Tandetnik
With sufficient thrust, pigs fly just fine. However, this is not
necessarily a good idea. It is hard to be sure where they are going to
land, and it could be dangerous sitting under them as they fly
overhead. -- RFC 1925