Jump to content
  • Advertisement
Sign in to follow this  
nihilisticod

2 windows message errors

This topic is 4810 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

Early today, I encountered two nifty little problems. Problem 1. My program was running correctly, I changed a Windowing class from a Singleton to a class with Static methods. Now, when I run the program in debug mode using MSVS 2003.net, I encounter a runtime error that occurs as soon as the window frame is displayed. I break to debug and it seems the problem occured in crt0.c on a call to winmain. The Local variables state that lpszCommandLine and StartupInfo are both bad pointers. I have no idea how to fix this and wondered if anyone had any advice. The only differences between the compile setups is that debug mode is not optimized, and uses a multi-threaded debug runtime library while Release is optimized and uses the multi-threaded runtime lib. Problem 2. The same program right now, when it runs, seems to crash upon any windows event message. Everything loads and runs fine, but as soon as I move the mouse or press a key, it crashes. I cannot get detailed info about the crash since It won't run in debug mode. I used a logfile to try and pinpoint the error and it seems the crash happens before WndProc is called back. just in case, I removed all function calls from WndProc. But that didn't help. If I get the first problem fixed I'm sure I can debug the second one. I suspect they are related since programs usually don't crash without reason (no matter how much I'd like to believe that). I'm sure I'm missing plenty of key information in this post but any help would be greatly appreciated.

Share this post


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

  • Advertisement
×

Important Information

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

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!