Replies: 1 comment 3 replies
|
The error was that the Window's function ftello64 and fread were not agreeing on the number of bytes to read. I fixed it by using ftello64's larger guess and then if fread didn't read all the bytes, it would be okay if at the end of file. There must be something weird with ftello64 or something, because it seems include the size of the file metadata or something, which isn't the case normally. I changed those other things to improve the readability a little bit while I was there, since the code was pretty bad and unnecessarily compacted. |
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Syntactic sugar doesn't work as expected? I found you replaced
unlesswith the plain oldif. Naming conflict? You also replacedlengthwithcapacityandread. This language has so many syntactic sugar that sometimes you get lost when reading code. It's kind of like you are reading code in another language. This will definitely cause problems. I admit I can't remember all of the syntactic sugar and only stick to the C-like syntax.All reactions