From 8e51bf8b192921e4e97f4c6570c328e82d761f35 Mon Sep 17 00:00:00 2001 From: Paul Coene Date: Sat, 22 Apr 2023 08:49:34 -0400 Subject: [PATCH] Fix crash when Removing empty password protected channel. (#3298) --- ucs/chatchannel.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ucs/chatchannel.cpp b/ucs/chatchannel.cpp index a8fa146eb..a8a7cc797 100644 --- a/ucs/chatchannel.cpp +++ b/ucs/chatchannel.cpp @@ -701,11 +701,11 @@ void ChatChannelList::Process() { LogDebug("Empty temporary password protected channel [{}] being destroyed", CurrentChannel->GetName().c_str()); - RemoveChannel(CurrentChannel); + iterator.RemoveCurrent(); + } + else { + iterator.Advance(); } - - iterator.Advance(); - } }