Link to home
Create AccountLog in
Avatar of PMH4514
PMH4514

asked on

NTDLL Exception in VC++ 6.0 and CString allocations??

In my VC++ 6.0 app, I get debug mode crashes oftentimes inexplicably.. The  call stack always looks like this:

 
NTDLL! 7c90120e()
NTDLL! 7c94b575()
NTDLL! 7c96eec8()
NTDLL! 7c94b3d4()
NTDLL! 7c918831()
_heap_alloc_base(unsigned int 80) line 200
_heap_alloc_dbg(unsigned int 36, int 1, const char * 0x5f8d3b18 THIS_FILE, int 118) line 378 + 9 bytes
_nh_malloc_dbg(unsigned int 36, int 0, int 1, const char * 0x5f8d3b18 THIS_FILE, int 118) line 248 + 21 bytes
_malloc_dbg(unsigned int 36, int 1, const char * 0x5f8d3b18 THIS_FILE, int 118) line 165 + 27 bytes
operator new(unsigned int 36, int 1, const char * 0x5f8d3b18 THIS_FILE, int 118) line 373 + 22 bytes
operator new(unsigned int 36, const char * 0x5f8d3b18 THIS_FILE, int 118) line 65 + 19 bytes
CString::AllocBuffer(int 11) line 118 + 20 bytes
CString::AllocBeforeWrite(int 11) line 202
CString::AssignCopy(int 11, const unsigned short * 0x004ad29c `string') line 315
CString::operator=(const unsigned short * 0x004ad29c `string') line 346

Open in new window


any ideas what might be causing this or how to resolve it?

thanks!
Avatar of Subrat (C++ windows/Linux)
Subrat (C++ windows/Linux)
Flag of India image

Write some part of the code that uses assignment operator on CString in line 346
Avatar of PMH4514
PMH4514

ASKER

It looks exactly like this:

CString sLabel = _T("Power");

by the way I'm compiling UNICODE
At a guess it is something before that piece of code that is corrupting the stack.  Look through your code before that line.  What was the previous line that might have used heap allocations?
I'd suggest to download the appropriate symbol packages for your system, so your debugger can at least tell which functions these are in the call stack. Go to http://www.microsoft.com/whdc/devtools/debugging/symbolpkg.mspx#d ("Download Windows Symbol Packages")
Avatar of PMH4514

ASKER

Sorry for my delay in responding I was called to another project.  I will try the symbol packages and see if I can produce any more useful information.  
ASKER CERTIFIED SOLUTION
Avatar of PMH4514
PMH4514

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
This question has been classified as abandoned and is being closed as part of the Cleanup Program. See my comment at the end of the question for more details.