Click here to Skip to main content
15,892,005 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Questionhow to Convert FileTimeToSystemTime in win32. Pin
amitmistry_petlad 24-Dec-06 23:06
amitmistry_petlad 24-Dec-06 23:06 
AnswerRe: how to Convert FileTimeToSystemTime in win32. Pin
includeh1025-Dec-06 2:20
includeh1025-Dec-06 2:20 
QuestionRaise events from unmanaged to managed Pin
yoti1124-Dec-06 22:31
yoti1124-Dec-06 22:31 
AnswerRe: Raise events from unmanaged to managed Pin
567890123424-Dec-06 23:15
567890123424-Dec-06 23:15 
GeneralRe: Raise events from unmanaged to managed Pin
yoti1124-Dec-06 23:36
yoti1124-Dec-06 23:36 
GeneralRe: Raise events from unmanaged to managed Pin
567890123425-Dec-06 1:26
567890123425-Dec-06 1:26 
Questionuninitialized pointer Pin
rp_suman24-Dec-06 20:58
rp_suman24-Dec-06 20:58 
AnswerRe: uninitialized pointer Pin
includeh1025-Dec-06 2:25
includeh1025-Dec-06 2:25 
if(ptr)
{
delete [] ptr;
}

is totally bad C++ code.
just do:

delete [] ptr;

because if ptr==NULL, you delete it without any problem.
for code like above, you must init at begining like:

ptr=0;

if the ptr will be reused, you must init after delete like:

delete []ptr;
ptr=0;











AnswerRe: uninitialized pointer Pin
Michael Dunn25-Dec-06 5:27
sitebuilderMichael Dunn25-Dec-06 5:27 
GeneralRe: uninitialized pointer Pin
rp_suman26-Dec-06 19:08
rp_suman26-Dec-06 19:08 
GeneralRe: uninitialized pointer Pin
Michael Dunn26-Dec-06 20:57
sitebuilderMichael Dunn26-Dec-06 20:57 
GeneralThanks!! Re: uninitialized pointer Pin
rp_suman27-Dec-06 15:36
rp_suman27-Dec-06 15:36 
AnswerRe: uninitialized pointer Pin
Cristian Amarie25-Dec-06 5:31
Cristian Amarie25-Dec-06 5:31 
GeneralRe: uninitialized pointer Pin
Michael Dunn25-Dec-06 6:31
sitebuilderMichael Dunn25-Dec-06 6:31 
GeneralRe: uninitialized pointer Pin
Cristian Amarie25-Dec-06 7:18
Cristian Amarie25-Dec-06 7:18 
GeneralRe: uninitialized pointer Pin
rp_suman25-Dec-06 14:02
rp_suman25-Dec-06 14:02 
Questioncan we get the Floppy Driver's information? Pin
jakeyjia24-Dec-06 20:55
jakeyjia24-Dec-06 20:55 
AnswerRe: can we get the Floppy Driver's information? Pin
Cristian Amarie25-Dec-06 5:36
Cristian Amarie25-Dec-06 5:36 
GeneralRe: can we get the Floppy Driver's information? [modified] Pin
jakeyjia26-Dec-06 14:13
jakeyjia26-Dec-06 14:13 
QuestionHow to control Parallel port by programming Visual C++ Pin
BK200724-Dec-06 20:55
BK200724-Dec-06 20:55 
AnswerRe: How to control Parallel port by programming Visual C++ Pin
kasturi_haribabu25-Dec-06 22:47
kasturi_haribabu25-Dec-06 22:47 
Questionmutithreading, how to synchronize threads Pin
saania khan24-Dec-06 20:26
saania khan24-Dec-06 20:26 
AnswerRe: mutithreading, how to synchronize threads Pin
Mark Salsbery25-Dec-06 6:51
Mark Salsbery25-Dec-06 6:51 
QuestionExpandEnvironmentStrings Pin
Waldermort24-Dec-06 20:06
Waldermort24-Dec-06 20:06 
AnswerRe: ExpandEnvironmentStrings Pin
Michael Dunn24-Dec-06 20:31
sitebuilderMichael Dunn24-Dec-06 20:31 

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.