This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ftell() fails on files in shared folders


On Mar 21 00:12, Yuri Gribov wrote:
> > First of all, there's a bug in your testcase.
> 
> Nice catch. With fixed code O_RDWR and O_WRONLY no longer influence
> the result but the bug still remains.
> 
> > What filesystem is your remote FS? ÂPlease run
> 
> Done. All nodes seem to have same volume attributes.
> 
> > You could also run the testcase under strace, like this:
> 
> Done, here's the relevant part: for local (successful) run:
>   write: write(3, 0x402080, 8)
>   write: 8 = write(3, 0x402080, 8)
>   fhandler_base::lseek: setting file pointer to 8
>   lseek64: 8 = lseek(0, 3, 0)
>   fhandler_base::lseek: setting file pointer to 8
>   lseek64: 8 = lseek(0, 3, 0)
> and for remote:
>   write: write(3, 0x402080, 8)
>   write: 8 = write(3, 0x402080, 8)
>   fhandler_base::lseek: setting file pointer to 0
>   lseek64: 0 = lseek(0, 3, 0)

Apart from the bug in Cygwin's debug output, the problem is obviously
that your remote filesystem returns 0 as the current file size.  I have
no idea why it does that, and why only on your system.  What OS are
your remote filesystems running on?  I tried on Windows 2008, 7, and
2008R2 in every from<->to combination.

Can anybody else on this list observe this behaviour?


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]