[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bash's test and GNU test give different results [if file not there]
From: |
Dan Jacobson |
Subject: |
Re: bash's test and GNU test give different results [if file not there] |
Date: |
27 Feb 2002 06:33:41 +0800 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.1 |
Chet says I should file a bug on gnu.utils.bug.
[If you ask me, this will make GNU test "defective" like bash test,
but that is just me... anyway, I leave the solution to you pros.
I still hope to see lots of warnings in the manpages.]
>>>>> "Chet" == Chet Ramey <address@hidden> mailed me:
>> >>>>> "Dan" == Dan Jacobson <address@hidden> writes:
>>
Dan> $ test non_existant_file -ot . && echo preposterous
Dan> preposterous
Dan> $ /usr/bin/test non_existant_file -ot . && echo preposterous
Dan> $ test . -nt non_existant_file && echo preposterous
Dan> preposterous
Dan> $ /usr/bin/test . -nt non_existant_file && echo preposterous
Dan> $ echo $BASH_VERSION
Dan> 2.05.0(1)-release
>>
>> >>>>> "Chet" == Chet Ramey <address@hidden> writes:
>>
>> >> Erm, so did I find a big bug or not? Thanks.
>>
Chet> I don't think so. Non-existent files have their mtimes set to 0.
>>
>> OK, then what are we going to do about the different results test -ot, -nt
>> give for bash's test vs. the GNU test?
>>
>> Shall I repost to gnu.utils.bug instead?
Chet> Sure, file a bug report. The `-[x]t' tests originated with ksh, so
Chet> bash is compatible with ksh93. There's no reason to be deliberately
Chet> incompatible here.
--
http://www.geocities.com/jidanni/ Taiwan(04)25854780
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: bash's test and GNU test give different results [if file not there],
Dan Jacobson <=