From: Corinna Vinschen <corinna-cygwin@cygwin.com>
To: Michael Haubenwallner <michael.haubenwallner@ssi-schaefer.com>
Cc: cygwin@cygwin.com
Subject: Re: [ANNOUNCEMENT] TEST: Cygwin 3.0.0-0.3
Date: Wed, 06 Feb 2019 16:34:00 -0000 [thread overview]
Message-ID: <20190206163424.GD13951@calimero.vinschen.de> (raw)
In-Reply-To: <20190206162037.GC13951@calimero.vinschen.de>
[-- Attachment #1: Type: text/plain, Size: 2023 bytes --]
On Feb 6 17:20, Corinna Vinschen wrote:
> On Feb 6 15:28, Michael Haubenwallner wrote:
> > On 2/3/19 12:19 PM, Corinna Vinschen wrote:
> > > On Jan 31 20:48, Corinna Vinschen wrote:
> > >> On Jan 31 09:47, Michael Haubenwallner wrote:
> > >>> Hi Corinna,
> > >>>
> > >>> I'm missing that topic/forkables branch in the announcement - is that in?
> > >>> https://cygwin.com/ml/cygwin-patches/2017-q1/msg00053.html
> > >>
> > >> No, it's not. It hasn't been touched for almost two years so I forgot
> > >> about it.
> > >>
> > >> Does it still apply to current mainline? Will it still work correctly
> > >> in conjunction with the Windows 10 1709/1803/1809 changes in terms of
> > >> deleting and renaming files?
> >
> > Independent of topic/forkables: With Cygwin 3.0.0 replacing/removing an
> > exe or dll in use does fail on Server 2019 while it does succeed on 2012.
> > The error messages on Server 2019 is 'Permission denied'.
>
> Is that the new FILE_DISPOSITION_POSIX_SEMANTICS change by any chance?
>
> https://sourceware.org/git/?p=newlib-cygwin.git;a=commitdiff;h=a7f392686b5b2
>
> If so, sigh, no new API without drawbacks.
>
> I guess we have to fallback to the old method in certain cases.
Can you try this patch, please?
diff --git a/winsup/cygwin/syscalls.cc b/winsup/cygwin/syscalls.cc
index 62b9638447ab..a1fd6cc9c975 100644
--- a/winsup/cygwin/syscalls.cc
+++ b/winsup/cygwin/syscalls.cc
@@ -733,7 +733,11 @@ unlink_nt (path_conv &pc)
if (pc.file_attributes () & FILE_ATTRIBUTE_READONLY)
NtSetAttributesFile (fh, pc.file_attributes ());
NtClose (fh);
- goto out;
+ /* Trying to delete in-use executables and DLLs using
+ FILE_DISPOSITION_POSIX_SEMANTICS returns STATUS_CANNOT_DELETE.
+ Fall back to the old method. */
+ if (status != STATUS_CANNOT_DELETE)
+ goto out;
}
/* If the R/O attribute is set, we have to open the file with
Thanks,
Corinna
--
Corinna Vinschen
Cygwin Maintainer
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2019-02-06 16:34 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-30 21:23 Corinna Vinschen
2019-01-31 8:47 ` Michael Haubenwallner
2019-01-31 19:48 ` Corinna Vinschen
2019-02-03 11:19 ` Corinna Vinschen
2019-02-04 13:20 ` Michael Haubenwallner
2019-02-04 14:25 ` Corinna Vinschen
2019-02-05 8:42 ` Michael Haubenwallner
2019-02-05 9:45 ` Corinna Vinschen
2019-02-05 11:31 ` Michael Haubenwallner
2019-02-05 11:57 ` Corinna Vinschen
2019-02-06 14:28 ` Michael Haubenwallner
2019-02-06 16:20 ` Corinna Vinschen
2019-02-06 16:34 ` Corinna Vinschen [this message]
2019-02-07 7:07 ` Michael Haubenwallner
2019-02-06 19:20 ` Andrey Repin
2019-02-07 8:32 ` Michael Haubenwallner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190206163424.GD13951@calimero.vinschen.de \
--to=corinna-cygwin@cygwin.com \
--cc=cygwin@cygwin.com \
--cc=michael.haubenwallner@ssi-schaefer.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).