Mercurial > hg
changeset 806:3521e34f722a
Fix a segfault when not connected to a server
Bug reported by Mario Iseli.
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Fri, 14 Apr 2006 20:38:35 +0200 |
parents | 43c22f43964e |
children | f6cda389db48 |
files | mcabber/src/screen.c |
diffstat | 1 files changed, 14 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/mcabber/src/screen.c Fri Apr 14 19:17:09 2006 +0200 +++ b/mcabber/src/screen.c Fri Apr 14 20:38:35 2006 +0200 @@ -851,18 +851,26 @@ // at least to refresh the pending message flag. scr_UpdateMainStatus(FALSE); + // Clear the line + werase(chatstatusWnd); + + if (chatmode) + wprintw(chatstatusWnd, "~"); + + if (!current_buddy) { + if (forceupdate) { + update_panels(); + doupdate(); + } + return; + } + fullname = buddy_getname(BUDDATA(current_buddy)); btype = buddy_gettype(BUDDATA(current_buddy)); isgrp = btype & ROSTER_TYPE_GROUP; ismuc = btype & ROSTER_TYPE_ROOM; - // Clear the line - werase(chatstatusWnd); - - if (chatmode) - wprintw(chatstatusWnd, "~"); - if (isgrp) { buf_locale = from_utf8(fullname); mvwprintw(chatstatusWnd, 0, 5, "Group: %s", buf_locale);