diff options
author | Jim Meyering <meyering@redhat.com> | 2011-07-26 09:01:44 +0200 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2011-07-26 09:01:44 +0200 |
commit | 5f35396395a61a9dd60367066bd4495091bd6f88 (patch) | |
tree | 4a42d73eee0183625044b5766558671124c35e29 /tests/cp/existing-perm-dir | |
parent | e772bddde8295fe0fdaef05b3c4c5e967116c805 (diff) | |
download | coreutils-5f35396395a61a9dd60367066bd4495091bd6f88.tar.xz |
maint: use consistent style in C and test scripts
* src/copy.c (copy_internal): Adjust formatting style to conform with
guidelines in HACKING: put braces around two one-line "else" blocks.
* tests/cp/existing-perm-dir: Use $(...), not `...`, and
stat rather than ls+cut to get the mode string.
mode=$(stat --p=%A dst/dir)
Diffstat (limited to 'tests/cp/existing-perm-dir')
-rwxr-xr-x | tests/cp/existing-perm-dir | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/cp/existing-perm-dir b/tests/cp/existing-perm-dir index 6ef73f0a0..a8c281669 100755 --- a/tests/cp/existing-perm-dir +++ b/tests/cp/existing-perm-dir @@ -25,7 +25,7 @@ mkdir -p -m ug-s,u=rwx,g=,o= dst/dir || fail=1 cp -r src/. dst/ || fail=1 -mode=`ls -ld dst/dir | cut -b-10` +mode=$(stat --p=%A dst/dir) test "$mode" = drwx------ || fail=1 Exit $fail |