LibCore+LibHTTP+RequestServer: Send data via sockets instead of pipes

This brings the implementation on Unix in line with Windows, so we can
drop a few ifdefs.
This commit is contained in:
Zaggy1024
2026-01-17 18:21:25 -06:00
committed by Tim Flynn
parent a3f0b513b6
commit 84c0eb3dbf
Notes: github-actions[bot] 2026-02-06 11:26:19 +00:00
7 changed files with 50 additions and 55 deletions

View File

@@ -418,7 +418,7 @@ ErrorOr<void> kill(pid_t pid, int signal)
return {};
}
ErrorOr<size_t> transfer_file_through_pipe(int source_fd, int target_fd, size_t source_offset, size_t source_length)
ErrorOr<size_t> transfer_file_through_socket(int source_fd, int target_fd, size_t source_offset, size_t source_length)
{
// FIXME: We could use TransmitFile (https://learn.microsoft.com/en-us/windows/win32/api/mswsock/nf-mswsock-transmitfile)
// here. But in order to transmit a subset of the file, we have to use overlapped IO.