Jump to content
  • Advertisement
Sign in to follow this  
gav86

Mysterious Quit

This topic is 4627 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

OK well I was just writing up the beginnings of a program, just made a simple "clear screen to blue" for the time being. Anyway it worked fine, so I went to add a function for loading/displaying 2d images, which I screwed up (made it overcomplicated). I deleted all that stuff so the program was back to how it was before - just clear the screen to blue. It compiles fine but now when I run it it quits upon entering winmain. . . I ran the VC++6 debug and here is the output from that:
Quote:
Loaded 'ntdll.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\kernel32.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\user32.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\gdi32.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\advapi32.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\rpcrt4.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\d3d9.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\d3d8thk.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\msvcrt.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\version.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\winmm.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\uxtheme.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\MSCTF.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\mslbui.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\oleaut32.dll', no matching symbolic information found. Loaded 'C:\WINDOWS\system32\ole32.dll', no matching symbolic information found. The thread 0xE0 has exited with code 0 (0x0). The program 'C:\programming\cpp\DX\3DTest\Debug\3DTest.exe' has exited with code 0 (0x0).
Can someone tell me what on earth is going on!

Share this post


Link to post
Share on other sites
Advertisement
The "no matching symbolic information found" messages just mean that you don't have the necessary info to debug into those system files. It's very unlikely they have anything to do with your problem.

I don't know why your program exited.

Share this post


Link to post
Share on other sites
Do you have some kind of event loop and are you sure you enter it ? Sounds like the program is terminating prematurely to me.

Edit: Wow, that's what I call a tautology. I'll leave it here for future reference. [grin]

Share this post


Link to post
Share on other sites
Ive isolated the problem down to this area...

	wndHandle = CreateWindow("3DTest", 
"3DTest",
WS_OVERLAPPEDWINDOW,
CW_USEDEFAULT,
CW_USEDEFAULT,
800,
600,
NULL,
NULL,
hInstance,
NULL);
if (!wndHandle)
{
MessageBox(NULL, "!wndHandle", "message", MB_OK);
return false;
}


!wndHandle is true, which is causing the program to quit just after winmain() is entered.

HWND wndHandle is a global variable defined at the start of the file...

Share this post


Link to post
Share on other sites
I've encountered some incidents where a CRT assertion triggers, but instead of actually popping up an assertion dialog box, the CRT simply forced the app to exit when the assert failed.

As for finding the actual assertion? Good freaking luck. I usually resort to progressive elimination, commenting things until the app exits normally.

Share this post


Link to post
Share on other sites
LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
switch (message)
{
case WM_DESTROY:
PostQuitMessage(0);
break;
}
return DefWindowProc(hWnd, message, wParam, lParam);
}


Here is WndProc!

Can someone tell me how I might go about outputting GetLastError() . . to say a messagebox?

Share this post


Link to post
Share on other sites
Ok, the WindowProc isn't at fault. You could use the debugger to get the value of GetLastError(). Just assign it to a variable and look at it in the watch window.

Another shot in the dark:
Is RegisterClass still being used? Maybe the class stuff got axed as well.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!