1 diff --git a/src/copy.c b/src/copy.c
2 index cb9018f93..2a4ccc061 100644
5 @@ -502,7 +502,7 @@ write_zeros (int fd, off_t n_bytes)
11 /* Perform an efficient extent copy, if possible. This avoids
12 the overhead of detecting holes in hole-introducing/preserving
13 copy, and thus makes copying sparse files much more efficient.
14 @@ -1095,7 +1095,7 @@ infer_scantype (int fd, struct stat const *sb,
15 && ST_NBLOCKS (*sb) < sb->st_size / ST_NBLOCKSIZE))
16 return PLAIN_SCANTYPE;
20 scan_inference->ext_start = lseek (fd, 0, SEEK_DATA);
21 if (0 <= scan_inference->ext_start)
22 return LSEEK_SCANTYPE;
23 @@ -1377,7 +1377,7 @@ copy_reg (char const *src_name, char const *dst_name,
25 bool wrote_hole_at_eof = false;
29 scantype == LSEEK_SCANTYPE
30 ? lseek_copy (source_desc, dest_desc, buf, buf_size, hole_size,
31 scan_inference.ext_start, src_open_sb.st_size,
32 diff --git a/tests/seek-data-capable b/tests/seek-data-capable
33 index cc6372214..6e7a9ec1e 100644
34 --- a/tests/seek-data-capable
35 +++ b/tests/seek-data-capable
37 import sys, os, errno, platform
41 # Pass an _empty_ file
42 if len(sys.argv) != 2: