I have a problem using fseeko64
this is what i have tried
Code:
fseek(ci.saveHandles[0],0,SEEK_END);
fgetpos(ci.saveHandles[0],&curPos); // works, curPos = end of file
Code:
fseeko64(ci.saveHandles[0],0,SEEK_END);
fgetpos(ci.saveHandles[0],&curPos); // does not work , curPos = 0
Code:
fseeko64(ci.saveHandles[0],0,SEEK_END);
fseeko64(ci.saveHandles[0],0,SEEK_END);
fgetpos(ci.saveHandles[0],&curPos); //works, curPos = end of file
Code:
clearerr(ci.saveHandles[0]);
fseeko64(ci.saveHandles[0],0,SEEK_END);
fgetpos(ci.saveHandles[0],&curPos); //does not work
so something is wrong with the stream, but i dont know what. ferror returns 0 which means that there shouldnt not be anything wrong with it. Why isnt it possible to seplace all fseek's with fseeko64??
and since im still new to the usage of 64 bit file operations, is there anything else i should now about their usage?
(im still on winxp with mingw)