isupport updates

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@3219 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2004-01-25 18:18:18 +00:00 committed by cras
commit 33e7528edb
5 changed files with 60 additions and 36 deletions

View file

@ -404,15 +404,11 @@ static void sig_usermode(SERVER_REC *server)
static const char *get_nick_flags(SERVER_REC *server)
{
IRC_SERVER_REC *irc_server = (IRC_SERVER_REC *) server;
static char *std = "@%+";
char *prefix = g_hash_table_lookup(irc_server->isupport, "prefix");
const char *prefix =
g_hash_table_lookup(irc_server->isupport, "PREFIX");
if (prefix == NULL)
return std;
prefix = strchr(prefix, ')');
if (prefix != NULL || *++prefix == '\0') /* FIXME: ugly to modify it */
return std;
return prefix;
return prefix == NULL ? "" : prefix+1;
}
static void sig_connected(IRC_SERVER_REC *server)