Click here to Skip to main content
15,923,789 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Thread Question {MOD} Pin
Programm3r19-Jun-07 21:53
Programm3r19-Jun-07 21:53 
QuestionHow to create common memory for two ocx Pin
Surendra Vishwkarma19-Jun-07 19:24
Surendra Vishwkarma19-Jun-07 19:24 
GeneralRe: How to create common memory for two ocx Pin
Matthew Faithfull20-Jun-07 3:54
Matthew Faithfull20-Jun-07 3:54 
QuestionDebug Assertion Failed! _CrtIsValidHeapPointer( pUserData) Pin
Shouvik Das19-Jun-07 18:48
Shouvik Das19-Jun-07 18:48 
AnswerRe: Debug Assertion Failed! _CrtIsValidHeapPointer( pUserData) Pin
Jonathan [Darka]19-Jun-07 21:44
professionalJonathan [Darka]19-Jun-07 21:44 
AnswerRe: Debug Assertion Failed! _CrtIsValidHeapPointer( pUserData) Pin
Mike Dimmick20-Jun-07 4:14
Mike Dimmick20-Jun-07 4:14 
AnswerRe: Debug Assertion Failed! _CrtIsValidHeapPointer( pUserData) Pin
Hamid_RT20-Jun-07 8:59
Hamid_RT20-Jun-07 8:59 
GeneralRe: Debug Assertion Failed! _CrtIsValidHeapPointer( pUserData) Pin
Shouvik Das20-Jun-07 20:40
Shouvik Das20-Jun-07 20:40 
according to the following call stack

<br />
NTDLL! 7c901230() <br />
NTDLL! 7c96cd80() <br />
NTDLL! 7c960af8() <br />
KERNEL32! 7c85e9cf() <br />
_CrtIsValidHeapPointer(const void * 0x00032b78) line 1697<br />
_free_dbg_lk(void * 0x00032b78, int 1) line 1044 + 9 bytes <br />
_free_dbg(void * 0x00032b78, int 1) line 1001 + 13 bytes operator <br />
delete(void * 0x00032b78) line 351 + 12 bytes <br />
CString::FreeData() line 146 + 15 bytes <br />
CString::~CString() line 213 $E155() + 34 bytes <br />
doexit(int 0, int 0, int 0) line 353 <br />
exit(int 0) line 279 + 13 bytes <br />
mainCRTStartup() line 345 <br />
KERNEL32! 7c816fd7()<br />


It is clear the error was occuring tryin to free the CString objects which incidentally I had made global due to the requirements. Hence I refactored my application and passed them as reference.

What I inferred from the situation is that while tryin to free up the Cstring memory it encountered that the heap had already been unintiallized. however it is still unclear to me how was the heap cleared before even C Runtime tried to unregister it. I never explicitly have defined any destructors.



There are only two kinds of people who are really fascinating-people who know absolutely everything, and people who know absolutely nothing.
Oscar Wilde (1854-1900)
Regards...
Shouvik

Questionhow to switch from IDR_MAINFRAME to IDR_MENU1 Pin
vikramkarthik19-Jun-07 18:25
vikramkarthik19-Jun-07 18:25 
AnswerRe: how to switch from IDR_MAINFRAME to IDR_MENU1 Pin
Iain Clarke, Warrior Programmer19-Jun-07 23:33
Iain Clarke, Warrior Programmer19-Jun-07 23:33 
AnswerRe: how to switch from IDR_MAINFRAME to IDR_MENU1 Pin
Hamid_RT20-Jun-07 8:59
Hamid_RT20-Jun-07 8:59 
QuestionThread / Memory Pin
Rose8119-Jun-07 17:40
Rose8119-Jun-07 17:40 
AnswerRe: Thread / Memory Pin
Matthew Faithfull20-Jun-07 3:16
Matthew Faithfull20-Jun-07 3:16 
QuestionAn Strange Problem in constructor [modified] Pin
vibindia19-Jun-07 16:16
vibindia19-Jun-07 16:16 
AnswerRe: An Strange Problem in constructor [modified] Pin
George L. Jackson19-Jun-07 16:52
George L. Jackson19-Jun-07 16:52 
AnswerRe: An Strange Problem in constructor Pin
_anil_19-Jun-07 19:30
_anil_19-Jun-07 19:30 
GeneralRe: An Strange Problem in constructor Pin
Jonathan [Darka]19-Jun-07 21:46
professionalJonathan [Darka]19-Jun-07 21:46 
Questionthe anti-static dilemma Pin
Cyrilix19-Jun-07 15:13
Cyrilix19-Jun-07 15:13 
AnswerRe: the anti-static dilemma Pin
Mark Salsbery19-Jun-07 15:23
Mark Salsbery19-Jun-07 15:23 
AnswerRe: the anti-static dilemma Pin
Cedric Moonen19-Jun-07 21:00
Cedric Moonen19-Jun-07 21:00 
GeneralRe: the anti-static dilemma Pin
Cyrilix20-Jun-07 3:13
Cyrilix20-Jun-07 3:13 
GeneralRe: the anti-static dilemma Pin
Matthew Faithfull20-Jun-07 3:29
Matthew Faithfull20-Jun-07 3:29 
Questionwhy the data would change with no trace? Pin
kcynic19-Jun-07 12:57
kcynic19-Jun-07 12:57 
QuestionRe: why the data would change with no trace? Pin
Mark Salsbery19-Jun-07 14:26
Mark Salsbery19-Jun-07 14:26 
AnswerRe: why the data would change with no trace? Pin
kcynic20-Jun-07 0:24
kcynic20-Jun-07 0:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.