summaryrefslogtreecommitdiff
path: root/src/plugins/buflist
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2020-06-10 20:39:07 +0200
committerSébastien Helleu <flashcode@flashtux.org>2020-06-10 20:39:07 +0200
commit99a324b76f4dd91e15e6ccabf7ae5b97927105c5 (patch)
tree671bc0fed22f03da3dc57bc73b33b7a84a0ba112 /src/plugins/buflist
parentfad07d1ff2eeab5c503d20976b33f64ae3994024 (diff)
downloadweechat-99a324b76f4dd91e15e6ccabf7ae5b97927105c5.zip
buflist: add "window" pointer in bar item evaluation only if it's not NULL (if bar type is "window")
Diffstat (limited to 'src/plugins/buflist')
-rw-r--r--src/plugins/buflist/buflist-bar-item.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/buflist/buflist-bar-item.c b/src/plugins/buflist/buflist-bar-item.c
index 527805fb8..e82fc18bc 100644
--- a/src/plugins/buflist/buflist-bar-item.c
+++ b/src/plugins/buflist/buflist-bar-item.c
@@ -327,7 +327,8 @@ buflist_bar_item_buflist_cb (const void *pointer, void *data,
item_index = (int)((unsigned long)pointer);
weechat_hashtable_set (buflist_hashtable_pointers, "bar_item", item);
- weechat_hashtable_set (buflist_hashtable_pointers, "window", window);
+ if (window)
+ weechat_hashtable_set (buflist_hashtable_pointers, "window", window);
ptr_format = buflist_config_format_buffer_eval;
ptr_format_current = buflist_config_format_buffer_current_eval;