aboutsummaryrefslogtreecommitdiffstats
path: root/mumd/src/network/tcp.rs
diff options
context:
space:
mode:
Diffstat (limited to 'mumd/src/network/tcp.rs')
-rw-r--r--mumd/src/network/tcp.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/mumd/src/network/tcp.rs b/mumd/src/network/tcp.rs
index f767446..717b195 100644
--- a/mumd/src/network/tcp.rs
+++ b/mumd/src/network/tcp.rs
@@ -184,7 +184,7 @@ async fn send_packets(
async fn send_voice(
packet_sender: mpsc::UnboundedSender<ControlPacket<Serverbound>>,
- receiver: Arc<Mutex<Box<(dyn Stream<Item = VoicePacket<Serverbound>> + Unpin)>>>,
+ receiver: Arc<tokio::sync::Mutex<Box<(dyn Stream<Item = VoicePacket<Serverbound>> + Unpin)>>>,
phase_watcher: watch::Receiver<StatePhase>,
) {
let inner_phase_watcher = phase_watcher.clone();
@@ -196,7 +196,7 @@ async fn send_voice(
|| async {
packet_sender.send(receiver
.lock()
- .unwrap()
+ .await
.next()
.await
.unwrap()
@@ -208,6 +208,7 @@ async fn send_voice(
|| async {},
inner_phase_watcher.clone(),
).await;
+ debug!("Stopped sending TCP voice");
Some(Some(()))
},
|_| async {},