1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

io.c: get src_size from stp. Fix r66995.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66996 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
glass 2019-02-03 23:30:56 +00:00
parent 3f0c966603
commit cc1dbb61e0

1
io.c
View file

@ -10863,6 +10863,7 @@ nogvl_copy_file_range(struct copy_stream_struct *stp)
if (!S_ISREG(stp->src_stat.st_mode))
return 0;
src_size = stp->src_stat.st_size;
src_offset = stp->src_offset;
if (src_offset >= (off_t)0) {
src_offset_ptr = &src_offset;