quinn
quinn copied to clipboard
proto: write outgoing packets to caller-supplied memory
Connection::poll_transmit allocates and immediately returns a Vec<u8>. There's no reason it couldn't instead take a &mut [MaybeUninit<u8>] or similar, giving the caller much greater flexibility to reduce allocations/copies, particularly when working with e.g. registered io_uring buffers.