Jump to content
  • Advertisement
Sign in to follow this  
steve coward

Release mode stream exception

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

I am trying to debug a simple file parser. I believe the code was working before I added the MMGR memory management code written by Paul Nettle. However now it works only in debug mode and not release mode where it fails with a first chance Microsoft C++ exception. Any help anyone can offer would be greatly appreciated. Here is some relevant simplified, code

DPRINTF("%s\n", sRuleDef.operator LPCTSTR());
istringstream stream1(sRuleDef.operator LPCTSTR());
stream1 >> pSoundRules;
istream & operator>> (istream &is, CSoundRule* pSoundRule);

istream & operator>> (istream &is, CSoundRule* pSoundRule)
	DPRINTF("start CSoundRule istream & operator>>\n");
	DPRINTF("done CSoundRule istream & operator>>\n");
friend istream & operator>> (istream &is, CUnitRules* pRule);
void Assign(istream &is);

void CSoundRule::Assign(istream &is) {
	string sToken;

	while (getline(is, sValue)) {
		DPRINTF("%s \n", sValue.c_str());
Here is the output - soundrule:0 "file":ceva "location":0,0 "bcmdcenter":1 "minattenuation":0 "bloop":0 "numoutstanding":1 "soundnotused":1 start CSoundRule istream & operator>> soundrule:0 "file":ceva "location":0,0 "bcmdcenter":1 "minattenuation":0 "bloop":0 "numoutstanding":1 "soundnotused":1 Done Exception signaled here. If I comment out the while loop I do not get an exception. Any ideas on what I am doing wrong or on how I can debug this? Could this behavior be related to include file ordering with respect to the memory management code? thanks

Share this post

Link to post
Share on other sites
Guest Anonymous Poster
Stop using VC6, its horrifically broken! 2005 is FREE. Also, remove the MMGR and see if you still have the issues.

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.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!