|
-
April 17th, 1999, 06:38 PM
#1
Assertion Failure in fscanf
I'm trying to read an input file into my program so I can manipulate the data and display it in the output. When I run my program, I get an assertion failure message that reads "Expression: Stream !=NULL". The error occurs after attempting to read the fscanf command that is storing the data in a user defined data structure array. What does this mean? Any advice on how to debug or correct?
-
April 19th, 1999, 07:40 AM
#2
Re: Assertion Failure in fscanf
What it means is that the 1st argument (the FILE* for the file you are trying to read) is NULL. Perhaps your fopen failed? I suggest you step through the code that handles the file. Check that fopen returns a non-NULL value, and check that nothing resets the variable that holds the FILE* returned by fopen.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|