Xref: utzoo comp.unix.programmer:950 alt.sources.d:1414 Path: utzoo!utgpu!cs.utexas.edu!samsung!uunet!pmafire!uudell!sequoia!rpp386!jfh From: jfh@rpp386.cactus.org (John F Haugh II) Newsgroups: comp.unix.programmer,alt.sources.d Subject: Re: -x implementations Message-ID: <19017@rpp386.cactus.org> Date: 31 Jan 91 13:54:19 GMT References: <1943:Jan2619:34:3591@kramden.acf.nyu.edu> <2856@charon.cwi.nl> <8869@star.cs.vu.nl> <1991Jan29.153242.12335@convex.com> <8896@star.cs.vu.nl> Reply-To: jfh@rpp386.cactus.org (John F Haugh II) Organization: Lone Star Cafe and BBS Service Lines: 21 X-Clever-Slogan: Recycle or Die. In article <8896@star.cs.vu.nl> maart@cs.vu.nl (Maarten Litmaath) writes: >If your effective uid is that of user `foo', whereas your real uid is >that of user `bar': > > $ ls -l mailbox > -rw------- 1 foo 1079 Jan 30 19:26 mailbox > $ test -r mailbox || echo 'Huh? Is mailbox unreadable for me?' > >Access(2), a sick system call. (I _know_ it uses the real uid on >purpose.) The question test(1) is asking is wrong. test is supposed to return whether or not it =is= readable, not whether it =should= be readable. test(1) is the sick on. Any version of test(1) which relies on access(2) is broken. -- John F. Haugh II UUCP: ...!cs.utexas.edu!rpp386!jfh Ma Bell: (512) 832-8832 Domain: jfh@rpp386.cactus.org "13 of 17 valedictorians in Boston High Schools last spring were immigrants or children of immigrants" -- US News and World Report, May 15, 1990