Click here to Skip to main content
15,921,716 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Hashing algorithms Pin
Jörgen Sigvardsson19-Nov-06 5:36
Jörgen Sigvardsson19-Nov-06 5:36 
AnswerRe: Hashing algorithms Pin
Blake Miller22-Nov-06 3:58
Blake Miller22-Nov-06 3:58 
Questionfgetc/fputc crashes with long filenames [modified] Pin
chichina18-Nov-06 17:33
chichina18-Nov-06 17:33 
AnswerRe: fgetc/fputc crashes with long filenames Pin
PJ Arends18-Nov-06 18:45
professionalPJ Arends18-Nov-06 18:45 
GeneralRe: fgetc/fputc crashes with long filenames Pin
chichina18-Nov-06 18:59
chichina18-Nov-06 18:59 
AnswerRe: fgetc/fputc crashes with long filenames [modified] Pin
Steve Echols18-Nov-06 18:59
Steve Echols18-Nov-06 18:59 
GeneralRe: fgetc/fputc crashes with long filenames Pin
chichina18-Nov-06 19:04
chichina18-Nov-06 19:04 
GeneralRe: fgetc/fputc crashes with long filenames Pin
Steve Echols18-Nov-06 19:16
Steve Echols18-Nov-06 19:16 
Well, I'd say fp == null and fp2 == null, which indicate it couldn't open either file.

You need to check for that in your code:

fp = fopen(filename, "rb");<br />
if ( !fp )<br />
{<br />
   // you got problems<br />
   // I think you can check errno to find out the exact error<br />
}<br />



- S
50 cups of coffee and you know it's on!

GeneralRe: fgetc/fputc crashes with long filenames Pin
chichina18-Nov-06 19:22
chichina18-Nov-06 19:22 
GeneralRe: fgetc/fputc crashes with long filenames Pin
Steve Echols18-Nov-06 20:04
Steve Echols18-Nov-06 20:04 
GeneralRe: fgetc/fputc crashes with long filenames Pin
Michael Dunn18-Nov-06 20:33
sitebuilderMichael Dunn18-Nov-06 20:33 
GeneralRe: fgetc/fputc crashes with long filenames Pin
Steve Echols18-Nov-06 20:36
Steve Echols18-Nov-06 20:36 
GeneralRe: fgetc/fputc crashes with long filenames Pin
chichina18-Nov-06 21:21
chichina18-Nov-06 21:21 
AnswerRe: fgetc/fputc crashes with long filenames Pin
Michael Dunn18-Nov-06 19:17
sitebuilderMichael Dunn18-Nov-06 19:17 
GeneralRe: fgetc/fputc crashes with long filenames Pin
chichina18-Nov-06 19:39
chichina18-Nov-06 19:39 
GeneralRe: fgetc/fputc crashes with long filenames Pin
Steve Echols18-Nov-06 20:02
Steve Echols18-Nov-06 20:02 
GeneralRe: fgetc/fputc crashes with long filenames Pin
chichina18-Nov-06 20:24
chichina18-Nov-06 20:24 
GeneralRe: fgetc/fputc crashes with long filenames Pin
Michael Dunn18-Nov-06 20:31
sitebuilderMichael Dunn18-Nov-06 20:31 
GeneralRe: fgetc/fputc crashes with long filenames Pin
chichina18-Nov-06 20:40
chichina18-Nov-06 20:40 
GeneralRe: fgetc/fputc crashes with long filenames Pin
Steve Echols18-Nov-06 20:34
Steve Echols18-Nov-06 20:34 
AnswerRe: fgetc/fputc crashes with long filenames Pin
Scott Holt20-Nov-06 15:50
Scott Holt20-Nov-06 15:50 
GeneralRe: fgetc/fputc crashes with long filenames Pin
chichina20-Nov-06 16:00
chichina20-Nov-06 16:00 
QuestionHow source codeCRC10 ??? Pin
patter77718-Nov-06 16:49
patter77718-Nov-06 16:49 
QuestionConsole window output [modified] Pin
locoone18-Nov-06 16:01
locoone18-Nov-06 16:01 
AnswerRe: Console window output Pin
Michael Dunn18-Nov-06 16:50
sitebuilderMichael Dunn18-Nov-06 16:50 

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.