diff options
author | Lukas Larsson <[email protected]> | 2012-05-30 18:29:07 +0200 |
---|---|---|
committer | Lukas Larsson <[email protected]> | 2012-05-30 18:29:07 +0200 |
commit | 283cf3bbce1b31bfd9ef1cc82adaa23eb736a97f (patch) | |
tree | 2debae6c2e1f9e5c982d7d9b0216dd442e912acf /lib | |
parent | 70f1e73d83877a22e3bee4b9e95d676ada7eb317 (diff) | |
parent | e20207c4e86cc2f0e58381a8a10c84aa6c067d12 (diff) | |
download | otp-283cf3bbce1b31bfd9ef1cc82adaa23eb736a97f.tar.gz otp-283cf3bbce1b31bfd9ef1cc82adaa23eb736a97f.tar.bz2 otp-283cf3bbce1b31bfd9ef1cc82adaa23eb736a97f.zip |
Merge branch 'lukas/kernel/sendfile_fallback_fix/OTP-10098' into maint
* lukas/kernel/sendfile_fallback_fix/OTP-10098:
Fix chunk usage check
Diffstat (limited to 'lib')
-rw-r--r-- | lib/kernel/src/file.erl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/kernel/src/file.erl b/lib/kernel/src/file.erl index d8033ee192..cdb984c333 100644 --- a/lib/kernel/src/file.erl +++ b/lib/kernel/src/file.erl @@ -1258,7 +1258,7 @@ sendfile_fallback_int(File, Sock, Bytes, ChunkSize, BytesSent) when Bytes > BytesSent; Bytes == 0 -> Size = if Bytes == 0 -> ChunkSize; - (Bytes - BytesSent + ChunkSize) > 0 -> + (Bytes - BytesSent) < ChunkSize -> Bytes - BytesSent; true -> ChunkSize |