diff options
Diffstat (limited to 'src/ui')
-rw-r--r-- | src/ui/console.c | 8 | ||||
-rw-r--r-- | src/ui/rosterwin.c | 5 |
2 files changed, 8 insertions, 5 deletions
diff --git a/src/ui/console.c b/src/ui/console.c index d86fb158..76295d63 100644 --- a/src/ui/console.c +++ b/src/ui/console.c @@ -1511,11 +1511,13 @@ cons_roster_setting(void) else cons_show("Roster room private char (/roster) : none"); - char private_ch = prefs_get_roster_private_char(); - if (private_ch) + char* private_ch = prefs_get_roster_private_char(); + if (private_ch) { cons_show("Roster private char (/roster) : %c", private_ch); - else + free(private_ch); + } else { cons_show("Roster private char (/roster) : none"); + } gint contact_indent = prefs_get_roster_contact_indent(); cons_show("Roster contact indent (/roster) : %d", contact_indent); diff --git a/src/ui/rosterwin.c b/src/ui/rosterwin.c index 91b8e7cc..b9a84950 100644 --- a/src/ui/rosterwin.c +++ b/src/ui/rosterwin.c @@ -951,9 +951,10 @@ _rosterwin_private_chats(ProfLayoutSplit* layout, GList* orphaned_privchats) g_string_append_printf(privmsg, "(%d) ", privwin->unread); } - char ch = prefs_get_roster_private_char(); + char* ch = prefs_get_roster_private_char(); if (ch) { - g_string_append_printf(privmsg, "%c", ch); + g_string_append_printf(privmsg, "%s", ch); + free(ch); } g_string_append(privmsg, privwin->fulljid); |