diff options
| author | ruki <[email protected]> | 2019-10-28 22:40:27 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2019-10-28 10:02:46 +0800 |
| commit | 8bfbf6b7fb255cda1bfd3d970c7442ed0941104c (patch) | |
| tree | 356e02c9fece1f27909a64f6d270e0201ab270b5 /xmake/core/base/socket.lua | |
| parent | a6e3140520f31c756cc8982d3ab20eff95b75160 (diff) | |
add sendfile demo
Diffstat (limited to 'xmake/core/base/socket.lua')
| -rw-r--r-- | xmake/core/base/socket.lua | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/xmake/core/base/socket.lua b/xmake/core/base/socket.lua index 0dfae075b..47c358599 100644 --- a/xmake/core/base/socket.lua +++ b/xmake/core/base/socket.lua @@ -246,6 +246,7 @@ function _instance:sendfile(file, opt) local errors = nil if opt.block then while start < last do + -- TODO pass file/handle, improve block send real, errors = io.socket_sendfile(self._SOCK, file, start, last) if real > 0 then send = send + real |
