aboutsummaryrefslogtreecommitdiffstats
path: root/mumd/src/audio.rs
diff options
context:
space:
mode:
Diffstat (limited to 'mumd/src/audio.rs')
-rw-r--r--mumd/src/audio.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/mumd/src/audio.rs b/mumd/src/audio.rs
index 747716c..2d504cf 100644
--- a/mumd/src/audio.rs
+++ b/mumd/src/audio.rs
@@ -87,6 +87,17 @@ impl Audio {
}
}
}
+
+ pub fn remove_client(&self, session_id: u32) {
+ match self.client_streams.lock().unwrap().entry(session_id) {
+ Entry::Occupied(entry) => {
+ entry.remove();
+ }
+ Entry::Vacant(_) => {
+ eprintln!("tried to remove session id {} that doesn't exist", session_id);
+ }
+ }
+ }
}
impl ClientStream {