1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-28 13:56:37 +02:00

Fix crash when displaying groups in buffer nicklist

This commit is contained in:
Sebastien Helleu
2010-11-10 11:37:30 +01:00
parent c2b5076334
commit 7eabbc6bb7
+3 -1
View File
@@ -1220,10 +1220,12 @@ gui_bar_item_default_buffer_nicklist (void *data, struct t_gui_bar_item *item,
{
if (ptr_nick)
length += ptr_nick->group->level + 16 /* color */
+ 1 /* prefix */ + 16 /* color */
+ ((ptr_nick->prefix) ? strlen (ptr_nick->prefix) : 0)
+ 16 /* color */
+ strlen (ptr_nick->name) + 1;
else
length += ptr_group->level - 1
+ 16 /* color */
+ strlen (gui_nicklist_get_group_start (ptr_group->name))
+ 1;
}