This is the mail archive of the insight-prs@sources.redhat.com mailing list for the Insight project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: insight/93: stdio.h problems : fopen() returns no adress unless file is called toto.txt !!!


Synopsis: stdio.h problems : fopen() returns no adress unless file is called toto.txt !!!

Responsible-Changed-From-To: unassigned->kseitz
Responsible-Changed-By: kseitz
Responsible-Changed-When: Fri Jan  4 14:01:04 2002
Responsible-Changed-Why:
    got it
State-Changed-From-To: open->closed
State-Changed-By: kseitz
State-Changed-When: Fri Jan  4 14:01:04 2002
State-Changed-Why:
    Um.. Look at your program. It is doing exactly what it should be doing.
    
    You're opening "toto.txt". When that file is not found, fopen returns NULL, which is then blindly passed to feof, which segfaults on the NULL.
    
    What do you expect to happen? On my Red Hat linux 7.0 box, your program also crashes (with or without Insight).

http://sources.redhat.com/cgi-bin/gnatsweb.pl?cmd=view&pr=93&database=insight


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]