2 # Create and remove a directory with more than 254 files.
3 # An early version of my rewritten rm failed to remove all of
4 # the files on SunOS4 when there were 254 or more in a directory.
6 # And the rm from coreutils-5.0 exposes the same problem when there
7 # are 338 or more files in a directory on a Darwin-6.5 system
9 if test "$VERBOSE" = yes; then
15 t0
=`echo "$0"|sed 's,.*/,,'`.tmp
;tmp
=$t0/$$
16 trap 'status=$?; cd $pwd; rm -rf $t0 && exit $status' 0
17 trap '(exit $?); exit' 1 2 13 15
20 mkdir
-p $tmp || framework_fail
=1
21 cd $tmp || framework_fail
=1
23 # Create 500 files (20 * 25).
24 for i
in 0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j
; do
26 for j
in a b c d e f g h i j k l m n o p q r s t u v w x y
; do
29 touch $files || framework_fail
=1
32 test -f 0a || framework_fail
=1
33 test -f by || framework_fail
=1
34 cd $pwd || framework_fail
=1
36 if test $framework_fail = 1; then
37 echo 'failure in testing framework'
43 test -d $tmp && fail
=1