On Saturday 24 July 2004 11:03 am, Douglas Kojetin wrote: > I did this, but it did not appear to resolve the issue. I also noticed > that I could use the program 'strace' to see if the file open's used > the O_LARGEFILE flag -- which they apparently do not. > > I know the most efficient way of getting this resolved might be to have > the original author of the code do it, but can anyone point me toward > some references in adding the O_LARGEFILE flag in the file open's? > (i'm using gcc, by the way).
The other problems that you may have is any things like assumptions about the size of a variable that holds offsets into the file. For example, lseek's man page shows that the second type is an off_t. That's either 32 bits or 64 bits, depending on whether you've compiled the program to permit large file support. Of course, there's nothing stopping the original author from using an int to hold the offset to lseek. In that case, even if you open the file properly and compile the code with the right flags, you may overflow the offset variable. If he declared it as an off_t, then the compile flag will take care of changing the variable's size. Otherwise, you'll have to go find where he has something like int file_offset and change it to off_t file_offset Like I said, good luck. Hacks like this (just want it to support this one large file) take a few minutes...or all weekend. :-) ---Tom -- TriLUG mailing list : http://www.trilug.org/mailman/listinfo/trilug TriLUG Organizational FAQ : http://trilug.org/faq/ TriLUG Member Services FAQ : http://members.trilug.org/services_faq/ TriLUG PGP Keyring : http://trilug.org/~chrish/trilug.asc
