I'm afraid it's not the right solution. You didn't say you actually fixed
your threads shutdown.
WM_CLOSE to the window. You should handle shutdown in WM_CLOSE.
I would also recommend to avoid window creation in secondary threads. That
gives you too much PITA.
Problem solved!
Thanks to Joe's (Joseph M. Newcomer ) MVP web site
("surviving the release version") I was able to get some
debug info which prompted me to make a trivial code
change.
Here's a snippet of my relevant code....
//------------------------------------------------------------
void CWhwin::OnSysCommand( WPARAM nID, LPARAM lParam )
{
int id = nID & 0xfff0;
if(id == SC_CLOSE)
{
wh_shutdown();// contains the DestroyWindow call
return;
}//if id == SC_CLOSE
//Crashed in this next line on AMD dual core PC
if(id == SC_MAXIMIZE || id == SC_SIZE || id == SC_RESTORE)
{
...
//------------------------------------------------------------
On non-dual core systems, it never got to this line after
DestroyWindows
The fix was to set a flag in wh_shutdown and exit OnSysCommand
if set, ie
void CWhwin::OnSysCommand( WPARAM nID, LPARAM lParam )
{
if (shuttingdown)
return;
int id = nID & 0xfff0;
"WRH" <nospam@videotron.ca> wrote in message
news:eWC63AwyGHA.1268@TK2MSFTNGP02.phx.gbl...
Hello
I have an app that I wrote and have used for many years.
I override OnSysCommand SC_CLOSE and do my own
cleanup before doing DestroyWindow. This app worked
well on Windows 95/98/NT/2000/2003 and with XP
running on a Pentium P4. With XP on an AMD Athlon X2,
however, DestroyWindow throws an unhandled exception
at 0x0000000000e0e0e0e...but not always.
I can work around it with ExitProcess but just wondering
if anyone had similar experiences with AMD vs Intel.