aboutsummaryrefslogtreecommitdiff
path: root/testsuite
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2010-04-09 14:11:45 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2010-04-09 14:11:45 +0200
commite69ad87802139b7b62fc06ff5d5d09cc4245d5fc (patch)
tree5140bc5e536c722f9aa5a0896a7229cf9b2148b0 /testsuite
parent02365a6ef73defb8689d3ed5228125d72993dec9 (diff)
downloadbusybox-w32-e69ad87802139b7b62fc06ff5d5d09cc4245d5fc.tar.gz
busybox-w32-e69ad87802139b7b62fc06ff5d5d09cc4245d5fc.tar.bz2
busybox-w32-e69ad87802139b7b62fc06ff5d5d09cc4245d5fc.zip
tar: fix "hardlinks to symlinks chown" bug 1519.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'testsuite')
-rwxr-xr-xtestsuite/tar.tests29
1 files changed, 29 insertions, 0 deletions
diff --git a/testsuite/tar.tests b/testsuite/tar.tests
index dd8f11062..a96382932 100755
--- a/testsuite/tar.tests
+++ b/testsuite/tar.tests
@@ -69,6 +69,35 @@ dr-xr-x--- input_dir
69" \ 69" \
70"" "" 70"" ""
71 71
72testing "tar symlinks mode" '\
73rm -rf input_* test.tar 2>/dev/null
74>input_file
75chmod 741 input_file
76ln -s input_file input_soft
77mkdir input_dir
78chmod 550 input_dir
79ln input_file input_dir
80ln input_soft input_dir
81tar cf test.tar input_*
82tar tvf test.tar | sed "s/.*[0-9] input/input/"
83tar xf test.tar 2>&1
84echo Ok: $?
85ls -l . input_dir/* | grep input_ | sed "s/\\(^[^ ]*\\) .* input/\\1 input/"
86' "\
87input_dir/
88input_dir/input_file
89input_dir/input_soft -> input_file
90input_file -> input_dir/input_file
91input_soft -> input_dir/input_soft
92Ok: 0
93-rwxr----x input_dir/input_file
94lrwxrwxrwx input_file
95dr-xr-x--- input_dir
96-rwxr----x input_file
97lrwxrwxrwx input_file
98" \
99"" ""
100
72optional FEATURE_TAR_LONG_OPTIONS 101optional FEATURE_TAR_LONG_OPTIONS
73testing "tar --overwrite" "\ 102testing "tar --overwrite" "\
74rm -rf input_* test.tar 2>/dev/null 103rm -rf input_* test.tar 2>/dev/null