From: Jim Meyering Date: Sun, 21 Oct 2001 18:50:16 +0000 (+0000) Subject: yikes. put the preserve_metadata assignment *after* declarations. X-Git-Tag: FILEUTILS-4_1_1~77 X-Git-Url: http://git.ipfire.org/gitweb/index.cgi?a=commitdiff_plain;h=e735c8f6e0ab5b42bea1145cc25ddd01dac65813;p=thirdparty%2Fcoreutils.git yikes. put the preserve_metadata assignment *after* declarations. gcc-3.0 didn't complain. --- diff --git a/src/copy.c b/src/copy.c index 33e47418fa..1d61b1d365 100644 --- a/src/copy.c +++ b/src/copy.c @@ -1278,7 +1278,6 @@ copy_internal (const char *src_path, const char *dst_path, #ifdef S_ISLNK if (S_ISLNK (src_type)) { - preserve_metadata = 0; char *src_link_val = xreadlink (src_path); if (src_link_val == NULL) { @@ -1313,6 +1312,9 @@ copy_internal (const char *src_path, const char *dst_path, } } + /* There's no need to preserve timestamps or permissions. */ + preserve_metadata = 0; + if (x->preserve_ownership) { /* Preserve the owner and group of the just-`copied'