This is the mail archive of the
cygwin-patches
mailing list for the Cygwin project.
Re: [PATCH] Fix bogus fsync() error
- From: Corinna Vinschen <corinna-cygwin at cygwin dot com>
- To: cygwin-patches at cygwin dot com
- Date: Tue, 1 Feb 2011 09:47:15 +0100
- Subject: Re: [PATCH] Fix bogus fsync() error
- References: <4D471106.4050304@t-online.de>
- Reply-to: cygwin-patches at cygwin dot com
On Jan 31 20:44, Christian Franke wrote:
> If used on raw devices like /dev/sda fsync() always fails with
> EBADRQC (54) because FlushFileBuffers() always fails with
> ERROR_INVALID_FUNCTION (1).
>
> The attached patch fixes this by simply ignoring this error in the
> fhandler_base implementation. This should not affect any real flush
> errors which likely would return other error codes.
>
> An alternative approach would be to ignore the error only in a new
> fhandler_raw_dev/floppy::fsync(). IMO not worth the effort is this
> case.
I agree. I applied the patch.
Thanks,
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Project Co-Leader cygwin AT cygwin DOT com
Red Hat