- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have code which has the option of dumping memory to a file and then later reading this file to repopulate memory for a later run. I am noting that I can run the code in Release mode without error, and yet in Debug mode the READ statements crash with the claim, input beyond end of record.
The READ statements contain within the program two REWIND statements for the file. I have put some tracking statements to a file to see where the problem lies, but there is no apparent reading out of sequence.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You've got other /fpscomp options set in Debug and not release. These need to match. For example, you have /fpscomp:ioformat set in the Compatibility property page in Debug but not in release. General was set on the Compatibility page in Debug but as "Additional Options" in release. Make all these match.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
There is likely an error in your code, perhaps an uninitialized variable. Without a test case there's no way to tell. File I/O is not handled any differently in debug or release modes, so the difference is almost certainly variable related.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for sending the project file. You had /fpscomp:general set in the Debug configuration but not in Release, and this very definitely changes the structure of unformatted files.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If memory serves, the switch /fpscomp:general was set in the Debug configuration so that the output of my direct access files would be equivalent when running Debug or Release. Without this switch, the fixed record length file created with the Debug configuration had LF as an end-of-line indicator whereas the Release had CR/LF.
The bonking line at present is something along the lines of
WRITE(IOCODE) (ARRAY(I), I = 1, IJD)
or
READ(IOCODE) (ARRAY(I), I = 1, IJD)
where IJD is 0.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You've got other /fpscomp options set in Debug and not release. These need to match. For example, you have /fpscomp:ioformat set in the Compatibility property page in Debug but not in release. General was set on the Compatibility page in Debug but as "Additional Options" in release. Make all these match.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve,
Thank you for the help. The options have pointed out some old unique ways the file dumps were being synchronized, including the reading of formatted direct-access files as sequential files. This has improved several items, if only for code standardization.
Thank you again.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page