Blame patches/coreutils/no-chown-cp.patch
|
|
c01589 |
diff -ru coreutils-9.1.orig/src/copy.c coreutils-9.1/src/copy.c
|
|
|
c01589 |
--- coreutils-9.1.orig/src/copy.c 2022-04-15 15:53:28.000000000 +0200
|
|
|
c01589 |
+++ coreutils-9.1/src/copy.c 2023-02-07 21:10:41.696869950 +0100
|
|
|
c01589 |
@@ -859,6 +859,7 @@
|
|
|
c01589 |
}
|
|
|
c01589 |
}
|
|
|
c01589 |
|
|
|
c01589 |
+#if 0
|
|
|
c01589 |
if (! chown_failure_ok (x))
|
|
|
c01589 |
{
|
|
|
c01589 |
error (0, errno, _("failed to preserve ownership for %s"),
|
|
|
c01589 |
@@ -866,6 +867,7 @@
|
|
|
c01589 |
if (x->require_preserve)
|
|
|
c01589 |
return -1;
|
|
|
c01589 |
}
|
|
|
c01589 |
+#endif
|
|
|
c01589 |
|
|
|
c01589 |
return 0;
|
|
|
c01589 |
}
|
|
|
c01589 |
@@ -2877,6 +2879,7 @@
|
|
|
c01589 |
if (x->preserve_security_context)
|
|
|
c01589 |
restore_default_fscreatecon_or_die ();
|
|
|
c01589 |
|
|
|
c01589 |
+#if 0
|
|
|
c01589 |
if (x->preserve_ownership)
|
|
|
c01589 |
{
|
|
|
c01589 |
/* Preserve the owner and group of the just-'copied'
|
|
|
c01589 |
@@ -2900,6 +2903,7 @@
|
|
|
c01589 |
preserving owner/group is a potential security problem. */
|
|
|
c01589 |
}
|
|
|
c01589 |
}
|
|
|
c01589 |
+#endif
|
|
|
c01589 |
}
|
|
|
c01589 |
else
|
|
|
c01589 |
{
|
|
|
c01589 |
diff -ru coreutils-9.1.orig/src/cp.c coreutils-9.1/src/cp.c
|
|
|
c01589 |
--- coreutils-9.1.orig/src/cp.c 2023-02-07 21:11:39.720870709 +0100
|
|
|
c01589 |
+++ coreutils-9.1/src/cp.c 2023-02-07 21:06:22.167995788 +0100
|
|
|
c01589 |
@@ -303,6 +303,7 @@
|
|
|
c01589 |
}
|
|
|
c01589 |
}
|
|
|
c01589 |
|
|
|
c01589 |
+#if 0
|
|
|
c01589 |
if (x->preserve_ownership)
|
|
|
c01589 |
{
|
|
|
c01589 |
if (lchownat (dst_dirfd, src_name, p->st.st_uid, p->st.st_gid) != 0)
|
|
|
c01589 |
@@ -318,6 +319,7 @@
|
|
|
c01589 |
ignore_value (lchownat (dst_dirfd, src_name, -1, p->st.st_gid));
|
|
|
c01589 |
}
|
|
|
c01589 |
}
|
|
|
c01589 |
+#endif
|
|
|
c01589 |
|
|
|
c01589 |
if (x->preserve_mode)
|
|
|
c01589 |
{
|