Mercurial > hg
changeset 2353:73916eeef3cb
Fix display when sending message to a full JID
This path fixes a regression in mcabber 1.1.1.
The message was shown as if it was a MUC private message.
Thanks to Minoru for the report.
author | franky |
---|---|
date | Tue, 15 Sep 2020 21:31:00 +0200 |
parents | 1d4274111c5d |
children | 83a50c3b808e |
files | mcabber/mcabber/commands.c |
diffstat | 1 files changed, 7 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/mcabber/mcabber/commands.c Sun Sep 06 21:37:29 2020 +0200 +++ b/mcabber/mcabber/commands.c Tue Sep 15 21:31:00 2020 +0200 @@ -1289,9 +1289,13 @@ } // Check if we're sending a message to a conference room - isroom = !!roster_find(bare_jid, jidsearch, ROSTER_TYPE_ROOM); - muc_nick = jid_get_resource_name(fjid); - isroom = isroom && !muc_nick; + if (NULL != roster_find(bare_jid, jidsearch, ROSTER_TYPE_ROOM)) { + muc_nick = jid_get_resource_name(fjid); + isroom = !muc_nick; // if a resource is specified, then it's a muc private message, not a room + } else { + isroom = false; + muc_nick = NULL; + } // local part (UI, logging, etc.) if (subj)