gh-65920: Implement socket.sendfile with TransmitFile on Windows#112337
gh-65920: Implement socket.sendfile with TransmitFile on Windows#112337aisk wants to merge 17 commits intopython:mainfrom
socket.sendfile with TransmitFile on Windows#112337Conversation
socket.sendfile with TransmitFile on Windows
Misc/NEWS.d/next/Windows/2023-11-23-22-25-16.gh-issue-65920.6wWsHN.rst
Outdated
Show resolved
Hide resolved
…WsHN.rst Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
|
Hi @eryksun , sorry to bother you, but can you help me review this PR when you have time? Thanks very much! |
|
Bumping this PR. The community (and myself) seem to feel it is very disjointed that |
|
see https://learn.microsoft.com/windows/win32/api/mswsock/nf-mswsock-transmitfile#remarks
Never mind. There is a |
|
@imba-tjd Thank you for your review, I found that we still need to call TransmitFile by chunk if the file is too large. Updated. |
Overlapped.TransmitFilein_overlappedmodule to implementsocket.sendfile;Overlapped.getresultexto implement the timeout functionality, which have almost the same codes as existsOverlapped.getresult, just with diffenernt arguments. I split theOverlapped.getresultin to another function to share the codes.And some thought on
os.sendfile: #102898 (comment)