veb: fix large file transfer timeout (fix #22489) (#22924)

This commit is contained in:
Martin Skou 2024-11-21 07:53:19 +01:00 committed by GitHub
parent 9490115c9a
commit c2d96c33b3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -266,9 +266,10 @@ fn handle_write_file(mut pv picoev.Picoev, mut params RequestParams, fd int) {
}
mut conn := &net.TcpConn{
sock: net.tcp_socket_from_handle_raw(fd)
handle: fd
is_blocking: false
sock: net.tcp_socket_from_handle_raw(fd)
handle: fd
is_blocking: false
write_timeout: params.timeout_in_seconds * time.second
}
params.file_responses[fd].file.read_into_ptr(data, bytes_to_write) or {