Path: utzoo!utgpu!utstat!jarvis.csri.toronto.edu!mailrus!iuvax!rutgers!bellcore!texbell!uhnix1!sugar!peter From: peter@sugar.hackercorp.com (Peter da Silva) Newsgroups: comp.sys.amiga Subject: Re: AmigaDos vs Unix wildcards/pathnames Message-ID: <3662@sugar.hackercorp.com> Date: 22 Mar 89 12:09:23 GMT References: <352@sagpd1.UUCP> <6294@cbmvax.UUCP> <11242@ut-emx.UUCP> Organization: Sugar Land Unix - Houston Lines: 23 A reason for putting wildcards in the shell that hasn't been brought up yet: If you do the wildcard expansion in the program, then there's really no way to predict just how another program is going to do it. Under UNIX, I know that if I 'execl("/usr/local/random_program", "random", filename, 0);' then that program will correctly interpret the filename as a filename. It won't barf because it's got spaces in it, or because it's got a '*' in it (or a '#', for that matter), and so on. Even if I use "system" to run the program, I know that I can quote any funky characters in the filename with quotes or backslashes and it'll work. If I pass a quoted string to a random program on the Amiga (or MS-DOS, or any other system where the expansion is done by the program) I never know what it'll do. Speaking of quoting, how many of you are aware that '*' is the 'literal-next' character in AmigaDOS? It's not surprising, since that's how it works in BCPL, and it's documented... but how many folks out there honor it? Why would you need it? What if you have a file with any one of '#?"' in it? How do you quote that? -- Peter "Have you hugged your wolf today" da Silva `-_-' ...texbell!sugar!peter, or peter@sugar.hackercorp.com 'U`