diff options
author | fiaxh <git@lightrise.org> | 2022-08-21 20:01:12 +0200 |
---|---|---|
committer | fiaxh <git@lightrise.org> | 2022-08-22 13:16:46 +0200 |
commit | 14bc3d6717515e0b34b02ef5b5ad4c3ec52ccdc2 (patch) | |
tree | c9ec1d3c01633a4ba4357f216fa70db9186794a6 | |
parent | 0aa73c4569a90031d8a88173f8689c18d02ddbe2 (diff) | |
download | dino-14bc3d6717515e0b34b02ef5b5ad4c3ec52ccdc2.tar.gz dino-14bc3d6717515e0b34b02ef5b5ad4c3ec52ccdc2.zip |
Fix crash on call window closing
-rw-r--r-- | main/src/ui/call_window/call_window_controller.vala | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/main/src/ui/call_window/call_window_controller.vala b/main/src/ui/call_window/call_window_controller.vala index e0eca6dc..3fde9759 100644 --- a/main/src/ui/call_window/call_window_controller.vala +++ b/main/src/ui/call_window/call_window_controller.vala @@ -362,8 +362,11 @@ public class Dino.Ui.CallWindowController : Object { public override void dispose() { foreach (ulong handler_id in call_window_handler_ids) call_window.disconnect(handler_id); foreach (ulong handler_id in bottom_bar_handler_ids) call_window.bottom_bar.disconnect(handler_id); - foreach (string peer_id in participant_widgets.keys) { - remove_participant(peer_id); + + var participant_ids = new ArrayList<string>(); + participant_ids.add_all(participant_widgets.keys); + foreach (string participant_id in participant_ids) { + remove_participant(participant_id); } call_window_handler_ids = bottom_bar_handler_ids = new ulong[0]; |