From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13412 invoked by alias); 29 Mar 2018 10:24:00 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: List-Unsubscribe: X-Seq: 42563 Received: (qmail 29431 invoked by uid 1010); 29 Mar 2018 10:24:00 -0000 X-Qmail-Scanner-Diagnostics: from mail-wm0-f47.google.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(74.125.82.47):SA:0(-1.9/5.0):. Processed in 15.69838 secs); 29 Mar 2018 10:24:00 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, SPF_PASS,T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.1 X-Envelope-From: stephane.chazelas@gmail.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:mail-followup-to:references :mime-version:content-disposition:in-reply-to:user-agent; bh=u/rtNo/2xi0XyipRSf9UfJwT/mxxAr4P3cj3JJ9GsKw=; b=Mtut5mF/Yp9MVEEEy2ZMJCvOCChqdOJ99ibW7cNhy+Gpgeq0Ojt9/ie2rdPU5rj6tY oMbMDb+2tRoWSXQ0g5QJ9piXtH14M/dInDL7gTFBbP1MnNz8oqRILoS+lNtquUyiVTEc CZ3D5NdpkF7JOVoM9KHQHPIjLNv9RLNgYQsoPVj1XaCYyMgOcbTkUamNU59hffauJNBD 3MKN2TJO2r/DJVirSbDooPa0jNGzCm26Y3J/RCPi42R9vi0IMJVZPrKUApxbkGJFtGhG 2d5Enu+QBq3bMeX+QTw9Zq8QufS6g+PAUJTN8LyXlGrFGCFvz4YSY3ZgK8opAvdP8iUH pdsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:mail-followup-to :references:mime-version:content-disposition:in-reply-to:user-agent; bh=u/rtNo/2xi0XyipRSf9UfJwT/mxxAr4P3cj3JJ9GsKw=; b=Wqp5TWSU3k7CZOEEi2wS8kTT6bh02F20zLYHuSdfAUlBo4UyvGAHLRwLcbp4EcrqCE cew5SMWun3UBHu1Y1o521GuaaczO1X6/bOBcepe6/P5wopxDGmenYtEUNn5kTsTj3pCD mP/16nANCRha+lok+yKSyoYbyNcXPlgOAI2G24F2aQaph+KoraVe3B3uFFaZfep1YK1A 2hCAGD2pad0fBpPtUDicafUVJMownQcNmsIUpr7Jdp5QyjA+6qXax1Ug9jrneLdOmwXr f47MtY5aTctX/LVXNsyhmmiaDvgka628+4z5BObG+JVGo8YIvlWPHsxngqTA7uG33ifa +FjQ== X-Gm-Message-State: AElRT7E+13sFt7qewhTY5qOb+DhWlmwspz7PrdndY1q7pG4bxy2Xr7ey PmBjPubr2RpY1Xqsh1QZmuk= X-Google-Smtp-Source: AIpwx4+ETXEUn9EL/HccKpESvTFsl3tgbuXAUUuuzjn2GYAthSwxmmwNUW5jaYwZSW3Pskm2SYWaSg== X-Received: by 10.28.234.207 with SMTP id g76mr5743291wmi.149.1522319020817; Thu, 29 Mar 2018 03:23:40 -0700 (PDT) Date: Thu, 29 Mar 2018 11:23:39 +0100 From: Stephane Chazelas To: Tatsuyuki Ishi , Bart Schaefer , Mikael Magnusson , Zsh hackers list Subject: Re: [bug] Globbing fails with execute-only directory in path Message-ID: <20180329102339.GA12710@chaz.gmail.com> Mail-Followup-To: Tatsuyuki Ishi , Bart Schaefer , Mikael Magnusson , Zsh hackers list References: <20180329063707.GA8243@chaz.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180329063707.GA8243@chaz.gmail.com> User-Agent: Mutt/1.5.24 (2015-08-30) 2018-03-29 07:37:07 +0100, Stephane Chazelas: [...] > That reveals another difference between zsh and bash here (or > more like between bash and other shells): > > $ mkdir -p a/b/cd > $ zsh -o nocaseglob -c 'echo a/B/c*' > a/b/cd > $ yash -o nocaseglob -c 'echo a/b/C*' > a/b/cd > $ ksh93 -c 'echo ~(i)a/b/C*' > a/b/cd > $ bash -O nocaseglob -c 'echo a/B/c*' > a/B/c* > > yash manages to find a/b/cd here after I remove search read > permission to "a": > > $ chmod 111 a > $ ksh93 -c 'echo ~(i)a/b/C*' > ~(i)a/b/C* > $ yash -o nocaseglob -c 'echo a/b/C*' > a/b/cd [...] Sorry, my bad, I hadn't realised that was the wrong test case for yash. yash does behave like bash here: $ yash -o nocaseglob -c 'echo a/b/C*' a/b/cd $ yash -o nocaseglob -c 'echo a/B/C*' a/B/C* $ zsh -o nocaseglob -c 'echo a/B/C*' a/b/cd So it works for the chmod 111 case for the same reason as it works in bash: it's doesn't need to list directory at every path components to find matching files. In effect, in zsh echo a/b/c* is like: echo [aA]/[bB]/[cC]* And that command fails to match in every shell when "a" is not readable. -- Stephane