aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2018-11-02 15:37:50 +0100
committerFlorian Weimer <fweimer@redhat.com>2018-11-02 18:15:04 +0100
commit6e36266cec43aac8bb22457428343fcbd523f108 (patch)
treedca106a4c9781146810943274f70f6aa1259e119
parent599f7beee7f693926dc2775dc5054007c96b7b74 (diff)
downloadglibc-6e36266cec43aac8bb22457428343fcbd523f108.zip
glibc-6e36266cec43aac8bb22457428343fcbd523f108.tar.gz
glibc-6e36266cec43aac8bb22457428343fcbd523f108.tar.bz2
support/shell-container.c: Use support_copy_file_range
Reviewed-by: DJ Delorie <dj@redhat.com>
-rw-r--r--ChangeLog6
-rw-r--r--support/shell-container.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index da72d30..497f5b7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
2018-11-02 Florian Weimer <fweimer@redhat.com>
+ * support/shell-container.c (copy_func): Call
+ support_copy_file_range instead of copy_file_range to support
+ cross-device copies.
+
+2018-11-02 Florian Weimer <fweimer@redhat.com>
+
* support/test-container.c: Include <libc-pointer-arith.h> for
ALIGN_UP.
diff --git a/support/shell-container.c b/support/shell-container.c
index d303131..9bd90d3 100644
--- a/support/shell-container.c
+++ b/support/shell-container.c
@@ -119,7 +119,7 @@ copy_func (char **argv)
return 1;
}
- if (copy_file_range (sfd, 0, dfd, 0, st.st_size, 0) != st.st_size)
+ if (support_copy_file_range (sfd, 0, dfd, 0, st.st_size, 0) != st.st_size)
{
fprintf (stderr, "cp: cannot copy file %s to %s: %s\n",
sname, dname, strerror (errno));