Click here to Skip to main content
15,917,793 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: new-delete Pin
CPallini24-Jun-07 21:19
mveCPallini24-Jun-07 21:19 
AnswerRe: new-delete Pin
HakunaMatada24-Jun-07 21:20
HakunaMatada24-Jun-07 21:20 
AnswerRe: new-delete Pin
samira forooghi24-Jun-07 21:26
samira forooghi24-Jun-07 21:26 
AnswerRe: new-delete Pin
Stephen Hewitt24-Jun-07 21:34
Stephen Hewitt24-Jun-07 21:34 
AnswerRe: new-delete Pin
samira forooghi24-Jun-07 22:05
samira forooghi24-Jun-07 22:05 
GeneralRe: new-delete Pin
markkuk24-Jun-07 22:10
markkuk24-Jun-07 22:10 
GeneralRe: new-delete Pin
CPallini24-Jun-07 22:18
mveCPallini24-Jun-07 22:18 
GeneralRe: new-delete Pin
baerten24-Jun-07 22:10
baerten24-Jun-07 22:10 
char *temp = Myfunction(....);
CString str = temp;
delete[] temp;

Because i THINK CString copies the char's into his own locatet memory.
So you lost the pointer to the allocated memory of the funtion Myfuntion,
You need to save temporary the pointer, only to delete him.
Questioncommand window Pin
deeps_cute24-Jun-07 21:09
deeps_cute24-Jun-07 21:09 
QuestionHelp ................Please Pin
Y_Kaushik24-Jun-07 21:08
Y_Kaushik24-Jun-07 21:08 
AnswerRe: Help ................Please Pin
baerten24-Jun-07 21:15
baerten24-Jun-07 21:15 
AnswerRe: Help ................Please Pin
Cedric Moonen24-Jun-07 21:17
Cedric Moonen24-Jun-07 21:17 
GeneralRe: Help ................Please Pin
Y_Kaushik24-Jun-07 21:19
Y_Kaushik24-Jun-07 21:19 
QuestionHelp ................Please Pin
Y_Kaushik24-Jun-07 21:06
Y_Kaushik24-Jun-07 21:06 
AnswerRe: Help ................Please Pin
CPallini25-Jun-07 1:36
mveCPallini25-Jun-07 1:36 
Questionclass problem Pin
hanlei000000000924-Jun-07 21:03
hanlei000000000924-Jun-07 21:03 
AnswerRe: class problem Pin
CPallini24-Jun-07 21:13
mveCPallini24-Jun-07 21:13 
AnswerI got it Pin
hanlei000000000924-Jun-07 21:22
hanlei000000000924-Jun-07 21:22 
AnswerRe: I got it Pin
Rajkumar R24-Jun-07 22:56
Rajkumar R24-Jun-07 22:56 
GeneralI see. Thank you Pin
hanlei000000000925-Jun-07 14:43
hanlei000000000925-Jun-07 14:43 
QuestionVC++ Interface Pin
bijumon Mathew24-Jun-07 21:02
bijumon Mathew24-Jun-07 21:02 
AnswerRe: VC++ Interface Pin
HakunaMatada24-Jun-07 21:15
HakunaMatada24-Jun-07 21:15 
Questionhow copy the contant of buffer in to file Pin
Y_Kaushik24-Jun-07 20:56
Y_Kaushik24-Jun-07 20:56 
AnswerRe: how copy the contant of buffer in to file Pin
Hamid_RT24-Jun-07 20:59
Hamid_RT24-Jun-07 20:59 
GeneralRe: how copy the contant of buffer in to file Pin
Y_Kaushik24-Jun-07 21:32
Y_Kaushik24-Jun-07 21:32 

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.