mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-04-02 18:55:32 +00:00
aquatic_udp: move code only use in mio impl out of crate::common
This commit is contained in:
parent
81b7777a4a
commit
b10f7b89e7
16 changed files with 89 additions and 71 deletions
|
|
@ -51,13 +51,15 @@ pub async fn run_socket_worker(
|
|||
response_consumer_index,
|
||||
local_sender,
|
||||
socket.clone(),
|
||||
)).detach();
|
||||
))
|
||||
.detach();
|
||||
|
||||
for (_, receiver) in response_receivers.streams().into_iter() {
|
||||
spawn_local(send_responses(
|
||||
socket.clone(),
|
||||
receiver.map(|(response, addr)| (response.into(), addr)),
|
||||
)).detach();
|
||||
))
|
||||
.detach();
|
||||
}
|
||||
|
||||
send_responses(socket, local_receiver.stream()).await;
|
||||
|
|
@ -174,7 +176,7 @@ where
|
|||
|
||||
while let Some((response, src)) = stream.next().await {
|
||||
buf.set_position(0);
|
||||
|
||||
|
||||
::log::debug!("preparing to send response: {:?}", response.clone());
|
||||
|
||||
response
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue