www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2011/08/01/13:03:42

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Mon, 1 Aug 2011 19:02:48 +0200
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: bash-4.2 and symlink to folder that turns to be not executable
Message-ID: <20110801170248.GA8767@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <20110801115922 DOT GA1124 AT po8371> <20110801122425 DOT GX26203 AT calimero DOT vinschen DOT de> <20110801141318 DOT GA1696 AT po8371>
MIME-Version: 1.0
In-Reply-To: <20110801141318.GA1696@po8371>
User-Agent: Mutt/1.5.21 (2010-09-15)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Aug  1 16:12, Denis Excoffier wrote:
> On Mon, Aug 01, 2011 at 02:24:25PM +0200, Corinna Vinschen wrote:
> >>    access (/tmp/xxx/folder, W_OK) = 0
> >>    access (/tmp/xxx/folder, X_OK) = 0
> >>   eaccess (/tmp/xxx/folder, F_OK) = 0
> >>   eaccess (/tmp/xxx/folder, R_OK) = 0
> >>   eaccess (/tmp/xxx/folder, W_OK) = 0
> >>   eaccess (/tmp/xxx/folder, X_OK) = 0
> 
> Right, and me too. But if i replace in your testcase:
> eaccess(file, flag) with
> faccessat(0 /* not used if file is absolute */, file, flag, AT_EACCESS)
> (and also "e" : " " with " " : "f" for clarity)
> (and i have to include <fcntl.h>)
> 
> i obtain:
> 
> % ./corinna++ /tmp/xxx/folder
> faccess (/tmp/xxx/folder, F_OK) = 0
> faccess (/tmp/xxx/folder, R_OK) = 0
> faccess (/tmp/xxx/folder, W_OK) = 0
> faccess (/tmp/xxx/folder, X_OK) = -1 <Permission denied>

Ouch.  I made a mistake in a bracket term in faccessat.  Fixed in CVS.
Thanks for following up with more testing.


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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019