diff options
| author | Jie Liu <jeff.liu@oracle.com> | 2010-06-11 16:29:02 +0800 |
|---|---|---|
| committer | Jim Meyering <meyering@redhat.com> | 2010-06-11 15:30:58 +0200 |
| commit | 98b2a24d7f00fba786a81870c9c9c8ffb9b8f9cf (patch) | |
| tree | d75b52118f08cf537bf3393267eedca42c4a9869 | |
| parent | tests: accommodate varying filefrag -v "flags" output (diff) | |
| download | coreutils-98b2a24d7f00fba786a81870c9c9c8ffb9b8f9cf.tar.gz coreutils-98b2a24d7f00fba786a81870c9c9c8ffb9b8f9cf.zip | |
copy.c: add FIEMAP_FLAG_SYNC to fiemap ioctl
* src/copy.c (fiemap_copy): Force kernel to sync the source
file before mapping.
| -rw-r--r-- | src/copy.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/copy.c b/src/copy.c index f149be460..f48c74df7 100644 --- a/src/copy.c +++ b/src/copy.c @@ -191,6 +191,7 @@ fiemap_copy (int src_fd, int dest_fd, size_t buf_size, do { fiemap->fm_length = FIEMAP_MAX_OFFSET; + fiemap->fm_flags = FIEMAP_FLAG_SYNC; fiemap->fm_extent_count = count; /* When ioctl(2) fails, fall back to the normal copy only if it |
