From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14485 invoked by alias); 28 Mar 2017 18:01:41 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 22632 Received: (qmail 18670 invoked from network); 28 Mar 2017 18:01:41 -0000 X-Qmail-Scanner-Diagnostics: from mta04.eastlink.ca 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(24.224.136.10):SA:0(-0.7/5.0):. Processed in 1.019997 secs); 28 Mar 2017 18:01:41 -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=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,RP_MATCHES_RCVD,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.1 X-Envelope-From: rayandrews@eastlink.ca X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _spf.eastlink.ca designates 24.224.136.10 as permitted sender) X-Authority-Analysis: v=2.2 cv=O5RJhF1W c=1 sm=1 tr=0 a=6rezmb/UIRDlS4lXI2FI3g==:117 a=6rezmb/UIRDlS4lXI2FI3g==:17 a=IkcTkHD0fZMA:10 a=G6iHmQPhLf4voQre2okA:9 a=QEXdDO2ut3YA:10 X-EL-IP-NOAUTH: 24.207.97.252 Subject: Re: spaces in filenames should be a crime. To: zsh-users@zsh.org References: <0c1b9d89-edd0-a027-e2f1-d01c2d68fa4e@eastlink.ca> <20170326211805.GA8170@fujitsu.shahaf.local2> <7d210765-c730-da1d-bb22-19f26ce02c6e@inlv.org> <85ef8db4-4fda-8276-3058-ab319ccb68bc@eastlink.ca> <5a334edd-e146-a42a-11fd-0840c904554a@eastlink.ca> <60a213ad-6cb3-bef4-9e61-f2c1611a5e71@gmx.de> <20170328161025.GA8511@fujitsu.shahaf.local2> From: Ray Andrews Message-id: Date: Tue, 28 Mar 2017 11:01:33 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-version: 1.0 In-reply-to: <20170328161025.GA8511@fujitsu.shahaf.local2> Content-type: text/plain; charset=utf-8; format=flowed Content-transfer-encoding: 7bit On 28/03/17 09:10 AM, Daniel Shahaf wrote: > Ray Andrews wrote on Tue, Mar 28, 2017 at 07:29:24 -0700: >> ls is a passive recipient, there is no 'request'. Yes? > Yes: > > 1 % strace -fe execve sh -c 'ls -d /*' > 2 execve("/bin/sh", ["sh", "-c", "ls -d /*"], [/* 47 vars */]) = 0 > 3 Process 8717 attached > 4 [pid 8717] execve("/bin/ls", ["ls", "-d", "/bin", "/boot", "/dev", "/etc", "/home", "/initrd.img", "/lib", "/lib64", "/lost+found", "/media", "/mnt", ...], [/* 47 vars */]) = 0 > > That execve() line shows the 'argv' array in ls's main() will be. You > can see that it has no asterisks. > It must be frustrating for the list that after several years I still make these DOSy mistakes. The above code is most educational, thanks.