mirror of
https://github.com/irssi/irssi.git
synced 2024-12-04 14:46:39 -05:00
/BAN could crash when showing bans
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@628 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
c084cfc5ca
commit
9a2b8e95ed
@ -289,9 +289,10 @@ static void bans_show_channel(CHANNEL_REC *channel, IRC_SERVER_REC *server)
|
||||
BAN_REC *rec = tmp->data;
|
||||
|
||||
printformat(server, channel->name, MSGLEVEL_CRAP,
|
||||
*rec->setby == '\0' ? IRCTXT_BANLIST :
|
||||
IRCTXT_BANLIST_LONG, channel->name, rec->ban,
|
||||
rec->setby, (int) (time(NULL)-rec->time));
|
||||
(rec->setby == NULL || *rec->setby == '\0') ?
|
||||
IRCTXT_BANLIST : IRCTXT_BANLIST_LONG,
|
||||
channel->name, rec->ban, rec->setby,
|
||||
(int) (time(NULL)-rec->time));
|
||||
}
|
||||
|
||||
/* ..and show ban exceptions.. */
|
||||
@ -299,9 +300,10 @@ static void bans_show_channel(CHANNEL_REC *channel, IRC_SERVER_REC *server)
|
||||
BAN_REC *rec = tmp->data;
|
||||
|
||||
printformat(server, channel->name, MSGLEVEL_CRAP,
|
||||
*rec->setby == '\0' ? IRCTXT_EBANLIST :
|
||||
IRCTXT_EBANLIST_LONG, channel->name, rec->ban,
|
||||
rec->setby, (int) (time(NULL)-rec->time));
|
||||
(rec->setby == NULL || *rec->setby == '\0') ?
|
||||
IRCTXT_EBANLIST : IRCTXT_EBANLIST_LONG,
|
||||
channel->name, rec->ban, rec->setby,
|
||||
(int) (time(NULL)-rec->time));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user