From 6d1c661e21e4e1e436959542493b2841a2bac7cb Mon Sep 17 00:00:00 2001 From: Michael Vetter Date: Wed, 2 Feb 2022 21:57:44 +0100 Subject: [PATCH] Remove banned muc member from member list If I'm understing everything right the member should be removed here. muc_members_update() seems to have been writen for the same purpose. Fix https://github.com/profanity-im/profanity/issues/1594 --- src/event/server_events.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/event/server_events.c b/src/event/server_events.c index 0b7858a3..8a308207 100644 --- a/src/event/server_events.c +++ b/src/event/server_events.c @@ -908,8 +908,12 @@ sv_ev_room_occupent_banned(const char* const room, const char* const nick, const } Jid* jidp = jid_create_from_bare_and_resource(room, nick); + + muc_members_remove(room, jidp->fulljid); ProfPrivateWin* privwin = wins_get_private(jidp->fulljid); + jid_destroy(jidp); + if (privwin != NULL) { privwin_occupant_banned(privwin, actor, reason); }