diff options
Diffstat (limited to 'tests/mv')
-rwxr-xr-x | tests/mv/acl | 4 | ||||
-rwxr-xr-x | tests/mv/atomic | 4 | ||||
-rwxr-xr-x | tests/mv/backup-dir | 2 | ||||
-rwxr-xr-x | tests/mv/childproof | 4 | ||||
-rwxr-xr-x | tests/mv/diag | 4 | ||||
-rwxr-xr-x | tests/mv/dir-file | 4 | ||||
-rwxr-xr-x | tests/mv/dir2dir | 2 | ||||
-rwxr-xr-x | tests/mv/dup-source | 4 | ||||
-rwxr-xr-x | tests/mv/hard-2 | 4 | ||||
-rwxr-xr-x | tests/mv/hard-3 | 4 | ||||
-rwxr-xr-x | tests/mv/hard-4 | 4 | ||||
-rwxr-xr-x | tests/mv/hard-link-1 | 4 | ||||
-rwxr-xr-x | tests/mv/hard-verbose | 2 | ||||
-rwxr-xr-x | tests/mv/i-2 | 4 | ||||
-rwxr-xr-x | tests/mv/i-3 | 4 | ||||
-rwxr-xr-x | tests/mv/i-4 | 4 | ||||
-rwxr-xr-x | tests/mv/i-5 | 2 | ||||
-rwxr-xr-x | tests/mv/i-link-no | 2 | ||||
-rwxr-xr-x | tests/mv/into-self-4 | 4 | ||||
-rwxr-xr-x | tests/mv/leak-fd | 2 | ||||
-rwxr-xr-x | tests/mv/mv-special-1 | 4 | ||||
-rwxr-xr-x | tests/mv/no-target-dir | 2 | ||||
-rwxr-xr-x | tests/mv/part-fail | 4 | ||||
-rwxr-xr-x | tests/mv/part-hardlink | 4 | ||||
-rwxr-xr-x | tests/mv/part-rename | 4 | ||||
-rwxr-xr-x | tests/mv/part-symlink | 12 | ||||
-rwxr-xr-x | tests/mv/partition-perm | 4 | ||||
-rwxr-xr-x | tests/mv/perm-1 | 4 | ||||
-rwxr-xr-x | tests/mv/reply-no | 4 | ||||
-rwxr-xr-x | tests/mv/trailing-slash | 2 | ||||
-rwxr-xr-x | tests/mv/update | 4 |
31 files changed, 58 insertions, 58 deletions
diff --git a/tests/mv/acl b/tests/mv/acl index 52c6fe130..b29f0e8ea 100755 --- a/tests/mv/acl +++ b/tests/mv/acl @@ -2,7 +2,7 @@ # move files/directories across file system boundaries # and make sure acls are preserved -# Copyright (C) 2005 Free Software Foundation, Inc. +# Copyright (C) 2005, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -37,7 +37,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 t0="$t0 $other_partition_tmpdir" diff --git a/tests/mv/atomic b/tests/mv/atomic index a03c4de58..bb761bdc4 100755 --- a/tests/mv/atomic +++ b/tests/mv/atomic @@ -1,7 +1,7 @@ #!/bin/sh # ensure that mv doesn't first unlink its destination in one particular case -# Copyright (C) 2006 Free Software Foundation, Inc. +# Copyright (C) 2006, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -25,7 +25,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/backup-dir b/tests/mv/backup-dir index ea2c6b7d3..72ffce1eb 100755 --- a/tests/mv/backup-dir +++ b/tests/mv/backup-dir @@ -28,7 +28,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/childproof b/tests/mv/childproof index b6101d36e..41cdfce18 100755 --- a/tests/mv/childproof +++ b/tests/mv/childproof @@ -2,7 +2,7 @@ # Ensure that cp/mv don't clobber a just-copied file. # With fileutils-4.1 and earlier, this test would fail. -# Copyright (C) 2001, 2004 Free Software Foundation, Inc. +# Copyright (C) 2001, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -31,7 +31,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` tmp=childproof.$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/diag b/tests/mv/diag index c3aaa52e7..63eb3c628 100755 --- a/tests/mv/diag +++ b/tests/mv/diag @@ -1,7 +1,7 @@ #!/bin/sh # make sure we get proper diagnostics: e.g., with --target-dir=d but no args -# Copyright (C) 2000, 2004 Free Software Foundation, Inc. +# Copyright (C) 2000, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -28,7 +28,7 @@ fi pwd=`pwd` tmp=diag-$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap 'exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/dir-file b/tests/mv/dir-file index 417b51d53..9c540b293 100755 --- a/tests/mv/dir-file +++ b/tests/mv/dir-file @@ -1,7 +1,7 @@ #!/bin/sh # mv must fail when src and dest are mismatched directory/non-directory. -# Copyright (C) 2000 Free Software Foundation, Inc. +# Copyright (C) 2000, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -25,7 +25,7 @@ fi tmp=mv-mismatch-$$ pwd=`pwd` -trap "cd $pwd; rm -rf $tmp" 0 1 2 3 15 +trap 'cd "$pwd" && rm -rf $tmp' 0 1 2 3 15 framework_failure=0 mkdir $tmp || framework_failure=1 diff --git a/tests/mv/dir2dir b/tests/mv/dir2dir index 28462a44f..8518a6220 100755 --- a/tests/mv/dir2dir +++ b/tests/mv/dir2dir @@ -29,7 +29,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/dup-source b/tests/mv/dup-source index b3d86daad..7965c91a5 100755 --- a/tests/mv/dup-source +++ b/tests/mv/dup-source @@ -4,7 +4,7 @@ # made this fail: cp a a d/ # Ensure that mv fails with a similar command. -# Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc. +# Copyright (C) 2001, 2002, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -33,7 +33,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` tmp=dup-src.$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/hard-2 b/tests/mv/hard-2 index 7dcc6c34a..101f334d2 100755 --- a/tests/mv/hard-2 +++ b/tests/mv/hard-2 @@ -2,7 +2,7 @@ # Ensure that moving hard-linked arguments onto existing destinations works. # Likewise when using cp --preserve=link. -# Copyright (C) 2003 Free Software Foundation, Inc. +# Copyright (C) 2003, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -30,7 +30,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/hard-3 b/tests/mv/hard-3 index b51411775..0ab9521fa 100755 --- a/tests/mv/hard-3 +++ b/tests/mv/hard-3 @@ -2,7 +2,7 @@ # Ensure that using `cp --preserve=link' to copy hard-linked arguments # onto existing destinations works, even when one of the link operations fails. -# Copyright (C) 2003 Free Software Foundation, Inc. +# Copyright (C) 2003, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -42,7 +42,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/hard-4 b/tests/mv/hard-4 index d44df0852..118479af0 100755 --- a/tests/mv/hard-4 +++ b/tests/mv/hard-4 @@ -1,7 +1,7 @@ #!/bin/sh # ensure that mv removes a in this case: touch a; ln a b; mv a b -# Copyright (C) 2003, 2004 Free Software Foundation, Inc. +# Copyright (C) 2003, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -27,7 +27,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/hard-link-1 b/tests/mv/hard-link-1 index 03327ad14..dc345f110 100755 --- a/tests/mv/hard-link-1 +++ b/tests/mv/hard-link-1 @@ -2,7 +2,7 @@ # move a directory containing hard-linked files and # make sure the links are preserved -# Copyright (C) 1998, 1999, 2000, 2004 Free Software Foundation, Inc. +# Copyright (C) 1998, 1999, 2000, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -30,7 +30,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/hard-verbose b/tests/mv/hard-verbose index b46492e4a..9c02ac14d 100755 --- a/tests/mv/hard-verbose +++ b/tests/mv/hard-verbose @@ -28,7 +28,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/i-2 b/tests/mv/i-2 index a3f51102b..ae7c5a135 100755 --- a/tests/mv/i-2 +++ b/tests/mv/i-2 @@ -2,7 +2,7 @@ # Test both cp and mv for their behavior with -if and -fi # The standards (POSIX and SuS) dictate annoyingly inconsistent behavior. -# Copyright (C) 2000, 2001 Free Software Foundation, Inc. +# Copyright (C) 2000, 2001, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -34,7 +34,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` tmp=cp-mv-if-$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap 'exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/i-3 b/tests/mv/i-3 index cd59e66ad..937479e42 100755 --- a/tests/mv/i-3 +++ b/tests/mv/i-3 @@ -2,7 +2,7 @@ # Make sure that `mv file unwritable-file' prompts the user # and that `mv -f file unwritable-file' doesn't. -# Copyright (C) 2001, 2004 Free Software Foundation, Inc. +# Copyright (C) 2001, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -30,7 +30,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` tmp=mv-i.$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/i-4 b/tests/mv/i-4 index 7d547a1bd..594c155fb 100755 --- a/tests/mv/i-4 +++ b/tests/mv/i-4 @@ -1,7 +1,7 @@ #!/bin/sh # make sure `mv -i a b' does its job with a positive response -# Copyright (C) 2001, 2005 Free Software Foundation, Inc. +# Copyright (C) 2001, 2005, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -28,7 +28,7 @@ fi pwd=`pwd` tmp=mv-i4-$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap 'exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/i-5 b/tests/mv/i-5 index 8b29545d8..2fec7edf7 100755 --- a/tests/mv/i-5 +++ b/tests/mv/i-5 @@ -28,7 +28,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/i-link-no b/tests/mv/i-link-no index 70208317d..2931af60e 100755 --- a/tests/mv/i-link-no +++ b/tests/mv/i-link-no @@ -28,7 +28,7 @@ fi pwd=`pwd` tmp=i-link-no.$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/into-self-4 b/tests/mv/into-self-4 index 4c94f20d9..13357b78d 100755 --- a/tests/mv/into-self-4 +++ b/tests/mv/into-self-4 @@ -2,7 +2,7 @@ # confirm that `mv symlink symlink' doesn't remove symlink # Based on an example from David Luyer. -# Copyright (C) 2001, 2004 Free Software Foundation, Inc. +# Copyright (C) 2001, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -28,7 +28,7 @@ fi pwd=`pwd` tmp=mv-slink2.$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/leak-fd b/tests/mv/leak-fd index 347aacfd9..5e5bb1a83 100755 --- a/tests/mv/leak-fd +++ b/tests/mv/leak-fd @@ -36,7 +36,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 if test -z "$other_partition_tmpdir"; then diff --git a/tests/mv/mv-special-1 b/tests/mv/mv-special-1 index b4b42c5c6..dadcd697d 100755 --- a/tests/mv/mv-special-1 +++ b/tests/mv/mv-special-1 @@ -1,7 +1,7 @@ #! /bin/sh # Test "mv" with special files. -# Copyright (C) 1998, 1999, 2000, 2002, 2004, 2005 Free Software +# Copyright (C) 1998, 1999, 2000, 2002, 2004, 2005, 2006 Free Software # Foundation, Inc. # This program is free software; you can redistribute it and/or modify @@ -26,7 +26,7 @@ fi pwd=`pwd` tmp=mv-spec.$$ -trap 'status=$?; cd $pwd; exec 1>&2; rm -rf $tmp $other_partition_tmpdir && exit $status' 0 +trap 'status=$?; cd "$pwd" && exec 1>&2; rm -rf $tmp $other_partition_tmpdir && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 . $srcdir/setup diff --git a/tests/mv/no-target-dir b/tests/mv/no-target-dir index 36c2e0e86..cf4891c58 100755 --- a/tests/mv/no-target-dir +++ b/tests/mv/no-target-dir @@ -26,7 +26,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/part-fail b/tests/mv/part-fail index c4aae78e4..2bbd9d247 100755 --- a/tests/mv/part-fail +++ b/tests/mv/part-fail @@ -4,7 +4,7 @@ # This is a bit fragile since it relies on the string used # for EPERM: `permission denied'. -# Copyright (C) 2002, 2004 Free Software Foundation, Inc. +# Copyright (C) 2002, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -33,7 +33,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 if test -z "$other_partition_tmpdir"; then diff --git a/tests/mv/part-hardlink b/tests/mv/part-hardlink index 9fb6c00cd..9a8eac770 100755 --- a/tests/mv/part-hardlink +++ b/tests/mv/part-hardlink @@ -4,7 +4,7 @@ # For additional constraints, see the comment in copy.c. # Before coreutils-5.2.1, this test would fail. -# Copyright (C) 2004, 2005 Free Software Foundation, Inc. +# Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -31,7 +31,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 if test -z "$other_partition_tmpdir"; then diff --git a/tests/mv/part-rename b/tests/mv/part-rename index 50df1c265..a4b361010 100755 --- a/tests/mv/part-rename +++ b/tests/mv/part-rename @@ -3,7 +3,7 @@ # another, and giving it a different name at the destination would cause mv # to get a failed assertion. -# Copyright (C) 2000, 2002, 2004 Free Software Foundation, Inc. +# Copyright (C) 2000, 2002, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -30,7 +30,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 if test -z "$other_partition_tmpdir"; then diff --git a/tests/mv/part-symlink b/tests/mv/part-symlink index c7c6132ef..eb66779c6 100755 --- a/tests/mv/part-symlink +++ b/tests/mv/part-symlink @@ -2,7 +2,7 @@ # make sure cp and mv can handle many combinations of local and # other-partition regular/symlink'd files. -# Copyright (C) 2000, 2003, 2004 Free Software Foundation, Inc. +# Copyright (C) 2000, 2003, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -27,7 +27,7 @@ fi pwd=`pwd` tmp=part-sl.$$ -trap 'status=$?; cd $pwd; exec 1>&2; rm -rf $tmp $other_partition_tmpdir && exit $status' 0 +trap 'status=$?; cd "$pwd" && exec 1>&2; rm -rf $tmp $other_partition_tmpdir && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 pwd_tmp=$pwd/$tmp @@ -98,8 +98,8 @@ for copy in cp mv; do case "$args" in *loc_sl*) slink=$loc_sl ;; esac case "$args" in *rem_sl*) slink=$rem_sl ;; esac - echo $contents > $reg_abs || fail=1 - ln -nsf $reg_abs $slink || fail=1 + echo $contents > "$reg_abs" || fail=1 + ln -nsf "$reg_abs" $slink || fail=1 actual_args=`echo $args|sed 's,^,$,;s/ / $/'` actual_args=`eval echo $actual_args` @@ -124,13 +124,13 @@ for copy in cp mv; do | sed \ -e '/^total /d' \ -e s,$other_partition_tmpdir/,, \ - -e s,$pwd_tmp/,, \ + -e "s,$pwd_tmp/,," \ -e 's/^[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *//'`" ls2="`cd $other_partition_tmpdir && ls -gG --ignore=.err . \ | sed \ -e '/^total /d' \ -e s,$other_partition_tmpdir/,, \ - -e s,$pwd_tmp/,, \ + -e "s,$pwd_tmp/,," \ -e 's/^[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *//'`" echo "($ls) ($ls2)" diff --git a/tests/mv/partition-perm b/tests/mv/partition-perm index cf68aabd4..f510edf08 100755 --- a/tests/mv/partition-perm +++ b/tests/mv/partition-perm @@ -1,7 +1,7 @@ #!/bin/sh # Make sure permissions are preserved when moving from one partition to another. -# Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc. +# Copyright (C) 1999, 2000, 2001, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -33,7 +33,7 @@ fi pwd=`pwd` dir=p-perm-$$ -trap "cd $pwd; rm -rf $dir $other_partition_tmpdir" 0 1 2 3 15 +trap 'cd "$pwd" && rm -rf $dir $other_partition_tmpdir' 0 1 2 3 15 mkdir $dir diff --git a/tests/mv/perm-1 b/tests/mv/perm-1 index d1b5276b8..1b9ab289a 100755 --- a/tests/mv/perm-1 +++ b/tests/mv/perm-1 @@ -2,7 +2,7 @@ # ensure that mv gives one diagnostic, not two, when failing # due to lack of permissions -# Copyright (C) 2002, 2004 Free Software Foundation, Inc. +# Copyright (C) 2002, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -30,7 +30,7 @@ PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/reply-no b/tests/mv/reply-no index ba45cc056..fa338c893 100755 --- a/tests/mv/reply-no +++ b/tests/mv/reply-no @@ -1,7 +1,7 @@ #!/bin/sh # Ensure that `mv --reply=no f1 f2' works. -# Copyright (C) 2005 Free Software Foundation, Inc. +# Copyright (C) 2005, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -25,7 +25,7 @@ fi pwd=`pwd` t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$ -trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0 +trap 'status=$?; cd "$pwd" && chmod -R u+rwx $t0 && rm -rf $t0 && exit $status' 0 trap '(exit $?); exit $?' 1 2 13 15 framework_failure=0 diff --git a/tests/mv/trailing-slash b/tests/mv/trailing-slash index 96201cf12..b734624de 100755 --- a/tests/mv/trailing-slash +++ b/tests/mv/trailing-slash @@ -28,7 +28,7 @@ fi pwd=`pwd` tmp=mv-tslash.$$ -trap 'status=$?; cd $pwd; exec 1>&2; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && exec 1>&2; rm -rf $tmp && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 . $srcdir/../envvar-check diff --git a/tests/mv/update b/tests/mv/update index 78bb7d2f8..6bf161efa 100755 --- a/tests/mv/update +++ b/tests/mv/update @@ -1,7 +1,7 @@ #!/bin/sh # make sure --update works as advertised -# Copyright (C) 2001, 2004 Free Software Foundation, Inc. +# Copyright (C) 2001, 2004, 2006 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -29,7 +29,7 @@ fi pwd=`pwd` tmp=mv-update.$$ -trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0 +trap 'status=$?; cd "$pwd" && rm -rf $tmp && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 framework_failure=0 |