GUI: Fix Tomato RAF theme for all builds. Compilation typo.
[tomato.git] / release / src-rt-6.x.4708 / tools / misc / xz / tests / test_files.sh
blob2fa83825e5fd944c9e4375c0c4b88c5a4b3bc12b
1 #!/bin/sh
3 ###############################################################################
5 # Author: Lasse Collin
7 # This file has been put into the public domain.
8 # You can do whatever you want with this file.
10 ###############################################################################
12 # If both xz and xzdec were not build, skip this test.
13 XZ=../src/xz/xz
14 XZDEC=../src/xzdec/xzdec
15 test -x "$XZ" || XZ=
16 test -x "$XZDEC" || XZDEC=
17 if test -z "$XZ$XZDEC"; then
18 (exit 77)
19 exit 77
22 for I in "$srcdir"/files/good-*.xz
24 if test -z "$XZ" || "$XZ" -dc "$I" > /dev/null 2>&1; then
26 else
27 echo "Good file failed: $I"
28 (exit 1)
29 exit 1
32 if test -z "$XZDEC" || "$XZDEC" "$I" > /dev/null 2>&1; then
34 else
35 echo "Good file failed: $I"
36 (exit 1)
37 exit 1
39 done
41 for I in "$srcdir"/files/bad-*.xz
43 if test -n "$XZ" && "$XZ" -dc "$I" > /dev/null 2>&1; then
44 echo "Bad file succeeded: $I"
45 (exit 1)
46 exit 1
49 if test -n "$XZDEC" && "$XZDEC" "$I" > /dev/null 2>&1; then
50 echo "Bad file succeeded: $I"
51 (exit 1)
52 exit 1
54 done
56 (exit 0)
57 exit 0