Re: SetEndOfFile fix

2002-01-29 Thread Guy L. Albertelli
- Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Sunday, January 27, 2002 4:30 PM Subject: Re: SetEndOfFile fix On Sun, 27 Jan 2002, Rein Klazes wrote: You still need ftruncate in case the file has to shrink. To do

Re: SetEndOfFile fix

2002-01-27 Thread Rein Klazes
On Sat, 26 Jan 2002 22:48:42 -0500 (EST), you wrote: On Sat, 26 Jan 2002, Guy L. Albertelli wrote: All the following is on the 2.2.12-20 kernel: ftruncate would return a 0. However Scandisk said that the file was bad. The length reported in the directory was larger than the

Re: SetEndOfFile fix

2002-01-26 Thread Rein Klazes
On Sat, 26 Jan 2002 01:48:06 -0500, you wrote: This was a great catch. It was the reason Scandisk complained about OutlookExpress's files (see my message from 1/11/2001). However your fix still fails on my outdated kernel (2.2.12-20). The attached version seems to work better on this

Re: SetEndOfFile fix

2002-01-26 Thread Duane Clark
Rein Klazes wrote: BTW, what goes wrong exactly? From the snippet above I understand that either ftruncate() moves the filepointer when it fails or that the sequence: lseek(fd,-1,SEEK_CUR);write(fd,buf,1) moves the file pointer. For your perusal, codeweavers also had a reimplementation of

Re: SetEndOfFile fix

2002-01-26 Thread lawson_whitney
On Sat, 26 Jan 2002, Guy L. Albertelli wrote: All the following is on the 2.2.12-20 kernel: ftruncate would return a 0. However Scandisk said that the file was bad. The length reported in the directory was larger than the allocated space. Errors were also reported on attempts to move or

Re: SetEndOfFile fix

2002-01-25 Thread Guy L. Albertelli
- Original Message - From: Rein Klazes [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, January 20, 2002 2:13 PM Subject: SetEndOfFile fix hi, This fixes office 97 MSword error (disk full or write protected) when saving files on a vfat partition. MSword calls SetEndOfFile

Re: SetEndOfFile fix

2002-01-20 Thread lawson_whitney
On Sun, 20 Jan 2002, Rein Klazes wrote: hi, BTW. A google search shows that the ftruncate problem has been mentioned at least 3 times on c.e.m.w. in the last 6 months Since nobody entered a fix, I could be overlooking something... Not exactly, I think. I remember several mentions of