summaryrefslogtreecommitdiff
path: root/src/cp.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1997-10-06 04:58:05 +0000
committerJim Meyering <jim@meyering.net>1997-10-06 04:58:05 +0000
commiteb2947bbbd14a3231f61870496c6038c8cf81a92 (patch)
tree77880b7c68fdd8b58515ca2023904a3d2a5451bc /src/cp.c
parentfe12b6711354443b38c583936ac1546a13423414 (diff)
downloadcoreutils-eb2947bbbd14a3231f61870496c6038c8cf81a92.tar.xz
(cp_option_init): Initialize it.
(main): Set to 1 for -a and for -p.
Diffstat (limited to 'src/cp.c')
-rw-r--r--src/cp.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/cp.c b/src/cp.c
index e2436400e..5a0d59712 100644
--- a/src/cp.c
+++ b/src/cp.c
@@ -587,6 +587,7 @@ cp_option_init (struct cp_options *x)
x->myeuid = geteuid ();
x->one_file_system = 0;
x->preserve = 0;
+ x->require_preserve = 0;
x->recursive = 0;
x->sparse_mode = SPARSE_AUTO;
x->symbolic_link = 0;
@@ -647,6 +648,7 @@ main (int argc, char **argv)
case 'a': /* Like -dpR. */
x.dereference = 0;
x.preserve = 1;
+ x.require_preserve = 1;
x.recursive = 1;
x.copy_as_regular = 0;
break;
@@ -675,6 +677,7 @@ main (int argc, char **argv)
case 'p':
x.preserve = 1;
+ x.require_preserve = 1;
break;
case 'P':