windows - Freepascal finding eof after reset of a non-empty file -
got me stumped: on windows, free pascal
{... writes text lines pdftmp, ...} close(pdftmp); reset(pdftmp); while not eof(pdftmp) begin readln(pdftmp,inpline); writeln(prodfile,inpline); end; close(pdftmp);
i've verified pdftmp file written text, eof() function returns true on first call, while block never executed.
i tried kinds of tricks surrounding code determine whatever else might causing failure, including updating fpc compiler, no avail. tests confirm improper eof() function result.
the same code works on mac. (freepascal supports various platforms.)
any other poor soul out there had evil befall , stall out nice project? if so, how fixed, if was?
Comments
Post a Comment