public inbox for cygwin-cvs@sourceware.org
help / color / mirror / Atom feed
From: Corinna Vinschen <corinna@sourceware.org>
To: cygwin-cvs@sourceware.org
Subject: [newlib-cygwin/cygwin-3_3-branch] Revert "Cygwin: fix permission problem when writing DAC info on Samba shares"
Date: Thu, 27 Jan 2022 14:30:48 +0000 (GMT)	[thread overview]
Message-ID: <20220127143048.A732C3858437@sourceware.org> (raw)

https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=7ac0767053e278f0ce9811bf6f77278bd2f49c20

commit 7ac0767053e278f0ce9811bf6f77278bd2f49c20
Author: Corinna Vinschen <corinna@vinschen.de>
Date:   Thu Jan 27 15:22:39 2022 +0100

    Revert "Cygwin: fix permission problem when writing DAC info on Samba shares"
    
    This reverts commit 0390cc85727b0165b5cdfcff7578cac94ae3371d.
    
    There's no indication what exact situation this patch was supposed to
    solve, and local testing doesn't show any such problems.  However, this
    patch itself introduced a new problem, as outlined by
    https://cygwin.com/pipermail/cygwin/2022-January/250629.html
    
    Signed-off-by: Corinna Vinschen <corinna@vinschen.de>

Diff:
---
 winsup/cygwin/fhandler.cc   | 6 ++----
 winsup/cygwin/release/3.3.4 | 4 ++++
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/winsup/cygwin/fhandler.cc b/winsup/cygwin/fhandler.cc
index 7d427135e..98d7a3b2d 100644
--- a/winsup/cygwin/fhandler.cc
+++ b/winsup/cygwin/fhandler.cc
@@ -561,12 +561,10 @@ fhandler_base::open (int flags, mode_t mode)
       access = READ_CONTROL | FILE_READ_ATTRIBUTES;
       break;
     case query_write_control:
-      access = READ_CONTROL | WRITE_OWNER | WRITE_DAC
-	       | (pc.fs_is_samba () ? 0 : FILE_WRITE_ATTRIBUTES);
+      access = READ_CONTROL | WRITE_OWNER | WRITE_DAC | FILE_WRITE_ATTRIBUTES;
       break;
     case query_write_dac:
-      access = READ_CONTROL | WRITE_DAC
-	       | (pc.fs_is_samba () ? 0 : FILE_WRITE_ATTRIBUTES);
+      access = READ_CONTROL | WRITE_DAC | FILE_WRITE_ATTRIBUTES;
       break;
     case query_write_attributes:
       access = READ_CONTROL | FILE_WRITE_ATTRIBUTES;
diff --git a/winsup/cygwin/release/3.3.4 b/winsup/cygwin/release/3.3.4
index d45722ac5..bc74e6914 100644
--- a/winsup/cygwin/release/3.3.4
+++ b/winsup/cygwin/release/3.3.4
@@ -33,3 +33,7 @@ Bug Fixes
 
 - Fix double free for archetype, which is caused when open() fails.
   Addresses: https://cygwin.com/pipermail/cygwin/2022-January/250518.html
+
+- Fix a permission problem when writing DOS attributes on Samba.
+  Addresses: https://cygwin.com/pipermail/cygwin/2022-January/250629.html
+


                 reply	other threads:[~2022-01-27 14:30 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20220127143048.A732C3858437@sourceware.org \
    --to=corinna@sourceware.org \
    --cc=cygwin-cvs@sourceware.org \
    /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).