I have a small socket app which works fine when statically linked to
MFC. Both server and client use threads and so I have the fix that is
mentioned in MSDN for statically linking to MFC (KB 193101).

If I change this to use MFC as a shared DLL, it crashes in
CThreadSlotData::GetThreadValue(). I am not sure why though. This
happens with and without the fix mentioned in the article.

Any suggestions?