Click here to Skip to main content
15,887,256 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Managing PushButton notifications under MFC Pin
tiwal27-Jul-11 3:23
tiwal27-Jul-11 3:23 
GeneralRe: Managing PushButton notifications under MFC Pin
Richard MacCutchan27-Jul-11 3:29
mveRichard MacCutchan27-Jul-11 3:29 
AnswerRe: Managing PushButton notifications under MFC Pin
Madhu Nair26-Jul-11 23:35
Madhu Nair26-Jul-11 23:35 
GeneralRe: Managing PushButton notifications under MFC [modified] Pin
tiwal26-Jul-11 23:46
tiwal26-Jul-11 23:46 
QuestionHow to compile a file using unicode charset Pin
Cold_Fearing_Bird26-Jul-11 21:50
Cold_Fearing_Bird26-Jul-11 21:50 
AnswerRe: How to compile a file using unicode charset Pin
Madhu Nair26-Jul-11 22:01
Madhu Nair26-Jul-11 22:01 
QuestionDelete doesn't ^delete^ a reference? Pin
Dean Seo25-Jul-11 20:58
Dean Seo25-Jul-11 20:58 
AnswerRe: Delete doesn't ^delete^ a reference? Pin
Richard MacCutchan25-Jul-11 21:24
mveRichard MacCutchan25-Jul-11 21:24 
This is one of the anomalies of delete in C++. When an object (or block of memory) is deleted then it is marked as free and may be re-used at some later time. However, the actual memory content, and any pointers to it, will not be physically cleared. If you had followed your delete statement with some other statement that needed to allocate memory, then it is likely that the program would have failed, as callFunc would (probably) be pointing at something that was not a test object.

When deleting objects you should always reset any pointers to NULL in order to protect yourself from any potential hazards.
The best things in life are not things.

GeneralRe: Delete doesn't ^delete^ a reference? Pin
Dean Seo26-Jul-11 14:11
Dean Seo26-Jul-11 14:11 
AnswerRe: Delete doesn't ^delete^ a reference? Pin
Chris Losinger26-Jul-11 1:45
professionalChris Losinger26-Jul-11 1:45 
GeneralRe: Delete doesn't ^delete^ a reference? Pin
Dean Seo26-Jul-11 14:10
Dean Seo26-Jul-11 14:10 
AnswerRe: Delete doesn't ^delete^ a reference? Pin
jschell26-Jul-11 9:48
jschell26-Jul-11 9:48 
GeneralRe: Delete doesn't ^delete^ a reference? Pin
Dean Seo26-Jul-11 14:09
Dean Seo26-Jul-11 14:09 
AnswerRe: Delete doesn't ^delete^ a reference? Pin
Stefan_Lang27-Jul-11 3:00
Stefan_Lang27-Jul-11 3:00 
GeneralRe: Delete doesn't ^delete^ a reference? Pin
jschell27-Jul-11 12:32
jschell27-Jul-11 12:32 
QuestionWorking with XML file in MFC Dialog based application? Pin
Le@rner25-Jul-11 20:27
Le@rner25-Jul-11 20:27 
AnswerRe: Working with XML file in MFC Dialog based application? Pin
Rajesh R Subramanian25-Jul-11 20:31
professionalRajesh R Subramanian25-Jul-11 20:31 
GeneralRe: Working with XML file in MFC Dialog based application? Pin
Le@rner25-Jul-11 21:02
Le@rner25-Jul-11 21:02 
GeneralRe: Working with XML file in MFC Dialog based application? Pin
Richard MacCutchan25-Jul-11 21:14
mveRichard MacCutchan25-Jul-11 21:14 
AnswerRe: Working with XML file in MFC Dialog based application? Pin
David Crow26-Jul-11 5:11
David Crow26-Jul-11 5:11 
GeneralRe: Working with XML file in MFC Dialog based application? Pin
Le@rner26-Jul-11 19:03
Le@rner26-Jul-11 19:03 
GeneralRe: Working with XML file in MFC Dialog based application? Pin
Rolf Kristensen27-Jul-11 12:05
Rolf Kristensen27-Jul-11 12:05 
QuestionDoes "parasoft c++ test" support VS2008? Pin
Cold_Fearing_Bird25-Jul-11 19:05
Cold_Fearing_Bird25-Jul-11 19:05 
AnswerRe: Does "parasoft c++ test" support VS2008? Pin
Code-o-mat25-Jul-11 22:07
Code-o-mat25-Jul-11 22:07 
QuestionA link problem with c++ template function Pin
Cold_Fearing_Bird25-Jul-11 15:14
Cold_Fearing_Bird25-Jul-11 15:14 

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.