From 8d548e1f88b83ea07e628bc6ddb7144ee8379bcd Mon Sep 17 00:00:00 2001 From: Sheldon Hearn Date: Wed, 15 Mar 2000 09:18:12 +0000 Subject: [PATCH] Do not preserve UIDs, permissions nor flags of package system files in tar files. This fixes clean-up problems during package creation and does not affect the actual files to be included in the package. The fix submitted on the attributed PR was identical to the one obtained from NetBSD. PR: 17386 Reported by: Adrian Filipi-Martin Obtained from: NetBSD --- usr.sbin/pkg_install/lib/file.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/pkg_install/lib/file.c b/usr.sbin/pkg_install/lib/file.c index b39ecf3b8f9..a2c2f3b831e 100644 --- a/usr.sbin/pkg_install/lib/file.c +++ b/usr.sbin/pkg_install/lib/file.c @@ -414,9 +414,9 @@ copy_file(char *dir, char *fname, char *to) char cmd[FILENAME_MAX]; if (fname[0] == '/') - snprintf(cmd, FILENAME_MAX, "cp -p -r %s %s", fname, to); + snprintf(cmd, FILENAME_MAX, "cp -r %s %s", fname, to); else - snprintf(cmd, FILENAME_MAX, "cp -p -r %s/%s %s", dir, fname, to); + snprintf(cmd, FILENAME_MAX, "cp -r %s/%s %s", dir, fname, to); if (vsystem(cmd)) { cleanup(0); errx(2, "could not perform '%s'", cmd);