Re: [PATCH 3/5] t/t1304: use 'test -r' to test readability rather than looking at mode bits
- From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
- Date
- Mar 15, 2010, 17:33 UTC
- Message-ID
- <vpq3a017am6.fsf@bauges.imag.fr>
- In-Reply-To
- <YowxgPZqaOkg2MZzY1CxL61O63C5ULimj64t69Bc-wsW3IlWf4Zc9WmA3ihonAb8UtR5thcko00@cipher.nrlssc.navy.mil>
Brandon Casey <casey@nrlssc.navy.mil> writes:
> - -r--r-----*) > - : happy > - ;;
> + test -r "$1" &&
Maybe it makes sense to ask for -r--?-----* instead, to make sure we don't give the read bit to anyone. But that's not really important since we're protected by the directory's permission anyway.
-- Matthieu Moy http://www-verimag.imag.fr/~moy/