diff options
| author | Gustav Sörnäs <gustav@sornas.net> | 2021-03-30 11:21:38 +0200 |
|---|---|---|
| committer | Gustav Sörnäs <gustav@sornas.net> | 2021-03-30 15:25:56 +0200 |
| commit | e1907114374c842654f86b234b816f57dbbc79d4 (patch) | |
| tree | 92595ffb0be7afcd19c7a2150010374f988b711a /mumd/src/client.rs | |
| parent | 8c3a37b40260711ef13a6130a612537b64b78215 (diff) | |
| download | mum-e1907114374c842654f86b234b816f57dbbc79d4.tar.gz | |
add StateError and AudioError
Diffstat (limited to 'mumd/src/client.rs')
| -rw-r--r-- | mumd/src/client.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mumd/src/client.rs b/mumd/src/client.rs index cdae7eb..6b66731 100644 --- a/mumd/src/client.rs +++ b/mumd/src/client.rs @@ -8,6 +8,7 @@ use std::sync::Arc; use tokio::{join, sync::{Mutex, mpsc, oneshot, watch}}; pub async fn handle( + state: State, command_receiver: mpsc::UnboundedReceiver<( Command, oneshot::Sender<mumlib::error::Result<Option<CommandResponse>>>, @@ -24,8 +25,8 @@ pub async fn handle( let (response_sender, response_receiver) = mpsc::unbounded_channel(); - let state = State::new(); let state = Arc::new(Mutex::new(state)); + join!( tcp::handle( Arc::clone(&state), |
