Skip to content

Commit d0b30a3

Browse files
devzero2000gitster
authored andcommitted
t/t5000-tar-tree.sh: avoid "test <cond> -a/-o <cond>"
The construct is error-prone; "test" being built-in in most modern shells, the reason to avoid "test <cond> && test <cond>" spawning one extra process by using a single "test <cond> -a <cond>" no longer exists. Signed-off-by: Elia Pinto <[email protected]> Reviewed-by: Matthieu Moy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 4399345 commit d0b30a3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

t/t5000-tar-tree.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ check_tar() {
7272
for header in *.paxheader
7373
do
7474
data=${header%.paxheader}.data &&
75-
if test -h $data -o -e $data
75+
if test -h $data || test -e $data
7676
then
7777
path=$(get_pax_header $header path) &&
7878
if test -n "$path"

0 commit comments

Comments
 (0)