From 6468f40dd97abff10de945c5cc731b078007fe0e Mon Sep 17 00:00:00 2001 From: James Booth Date: Tue, 21 Jan 2014 18:14:20 +0000 Subject: [PATCH] Convert name to barejid on retrieving win in titlebar for otr messages fixes #289 --- src/ui/titlebar.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/ui/titlebar.c b/src/ui/titlebar.c index d66d6c4a..83487aa4 100644 --- a/src/ui/titlebar.c +++ b/src/ui/titlebar.c @@ -29,6 +29,7 @@ #include "ui/ui.h" #include "ui/windows.h" #include "ui/window.h" +#include "roster_list.h" #define CONSOLE_TITLE "Profanity. Type /help for help information." @@ -158,7 +159,8 @@ _title_bar_draw(void) #ifdef HAVE_LIBOTR // show privacy if (current_recipient != NULL) { - ProfWin *current = wins_get_by_recipient(current_recipient); + char *recipient_jid = roster_barejid_from_name(current_recipient); + ProfWin *current = wins_get_by_recipient(recipient_jid); if (current != NULL) { if (current->type == WIN_CHAT) { if (!current->is_otr) {